The giving of Salam and to answer the greetings in a more pleasant manner is in the Quran. To me It is about the equality and the brotherhood of men.
When we follow that command it is an act of Submission n that men are equal before Him.
The acknowledgment of peace in a more pleasant manner is demanded, paving the way for more productive n blessed interactions between men of peace. I don’t discriminate when giving my salam