I need help, I want to send a encrypted SMS from Alice to Bob, where does hashing comes in here? How do I use the hashing??
Hashing, or really a Message Authentication Code (MAC) in this instance, would not be used in encrypting the message per se, but would be used to verify that the message had not been tampered with while in transit.
A traditional hashing function is a one-way function which takes an input (the text of your SMS message, in this case) give a unique output for that input. The same hashing function applied to the same input will always product the same output. A good hashing function is one that is mathematically easy to go from input to output, but is mathematically difficult to go from output back to the orginal input.
A Message Authentication Code is similar to a traditional hash in that it's difficult to go from output back to input, but it also takes a private key. This means that two users can take the same MAC function, put in the same data, but get two completely different results if the private keys do not match. The recipient of the message can then use the senders public key to validate that the sender was indeed the person that sent the message.
Building crypto systems is very hard to do correctly. If you need to communicate securely by phone, I would recommend that you use an existing, peer-reviewed app such as Signal.