Not authorized on admin to execute command updateUser

If anyone struggles with same problem here’s the answer I got from technical support:
In MongoDB Atlas, user management, including updating user credentials, is handled differently. Instead of using database commands like updateUser, you would need to manage users through the MongoDB Atlas UI.

Atlas enforces stricter controls over user management to ensure security and consistency across its managed service, which is why certain commands that are available in self-hosted MongoDB instances are restricted or unavailable.

The security model for Atlas is a bit different in Atlas than Enterprise. These commands are not supported in Atlas even for Organization Owner role. User and role management should be performed via the Atlas UI. For more information on this please review our documentation on Atlas User Roles.