Here are a couple of things to try.
Reboot your computer and see if the problem fixes itself..
If that doesn't fix the issue, please see if the problem still happens in Safe mode.
How to use safe mode on your Mac - Apple Support
Does the problem persist while in Safe mode? If not, then leave safe mode by restarting your Mac normally and re-evaluate the issue again after a normal reboot
If that doesn't work, trash the Mail preferences .plist file. It may have become corrupted.
Close the Mail app.
From Finder, option-click the Go menu > Library. Then double-click to open the Preferences folder.
Locate and delete the file "com.apple.mail.plist"
Logout of your User or restart the Mac and login again.
Check the Mail app and see if the new account has been created: Mail > Preferences > Accounts. If not, repeat the process for creating a Mail account... but first delete the currently created Gmail account in system Preferences > Internet Accounts.