By the way, we recommend having 2 administrator accounts on your PC/laptop, one for daily use and one for emergencies like this, the last one being a local account, not a Microsoft account. Then you can use the other account if you forgot the password of the first.
And I would recommend to use a password manager like keepass or lastpass to safely store passwords so you can't forget them.