Well you told us how to sign a message .. But please tell me why it is needed to sign a message. What is it used for and why to sign a message??

As Coinlearn wrote, to prove you own a bitcoin address. Why prove that you may ask.
You can use a signed message as proof of funds. Signing a message with an address that holds a certain amount of funds, shows that you held or hold that amount.
You can use a signed message to prove to someone that you are still the same person as last year. Accounts here are traded often, bitcoin addresses almost never. Its possible though, so its not 100%.
You can use a signed message to agree to a private agreement. Lets say you staked your address in the thread here[1] and want to make a deal with someone you both prefer to stay private for some reason. If you both sign the agreement with your staked addresses you can disclose the agreement if needed. This is often a requirement when bitcointalk accounts are sold. It gives security to the buyer, that the seller will not try to reclaim the account via a signed message to the admins.
You can use a signed message to prove to the admins that you are the rightful owner of a hacked account. Its usually the only way to get a stolen account back.
[1]
https://bt.irlbtc.com/view/996318.0