There are several steps in the password reset process, including:
• "If you don’t see a reset message, check again after entering a password up to three times."
• "Restart your Mac and try again"
• "Use the reset options in Recovery"
Finally, if none of the reset steps work -
❝If you can’t reset your login password
If no other solution works, you can regain access to your Mac by erasing it. This permanently removes each user account, its password, and its data from your Mac.
- Shut down your Mac, then start up from macOS Recovery again. When asked to select a user you know the password for, choose Recovery Assistant > Erase Mac from the menu bar at the top of the screen.
- In the window that opens, click Erase Mac, then click Erase Mac to confirm.❞
Guidance for all of this is in the article linked.