Not sure about Spanish, but in Slavic/Germanic languages it's as OP says, the plural form tends to show more respect for e.g. talking to a stranger, especially an older one. Students typically address teachers this way and teachers don't do it in return, until university where students are considered old enough and it's typically done mutually. People of the same age that know each other almost always just use singular form.
There are actually three forms if we're completely exact: singular 2nd person, plural 2nd person, and plural 3rd person. German uses the first and last, Slavic languages have all three but the third is very dated and practically unused by now.
There are actually three forms if we're completely exact: singular 2nd person, plural 2nd person, and plural 3rd person. German uses the first and last, Slavic languages have all three but the third is very dated and practically unused by now.