"You must use your real name here" is not discrimination and it is not illegal. It may be something you disagree with, but that's another matter.
Discrimination would be a "whites only" social network, and regardless of legality, I'm sure they exist.