There are two main settings which control this:
1. Under Admin -> Users -> User policies -> Show user identity, you can control which identifiers are siginificant to your organisation, and so should be shown in places like this.
2. The capability moodle/site:viewuseridentity - by controlling which roles have that
permission, you can control who sees that information, so only the people who need to see it can see it.
As Brett says, People enrolling other people in courses probably need a way to make sure they really have the right user.