When using the separate, unique-password mechanism in Notes app, Apple uses the password as the key for secure encryption and decryption, meaning you need that password to decrypt the data to do the rename.
No password, no data decryption, no data access.
That unique password isn’t stored anywhere, and Apple doesn’t know what the password is, so there’s also no saved password to change.
If you were using a separate, unique password and not the device password, then you’ll need to remember that separate, unique password to regain access. As correctly mentioned in the previous reply, you do (and unusually) get unlimited password tries, in this particular case. Unlimited retries is rare, in recent times.
Maybe look at Passwords app for other passwords created around the same time, as a reminder of the now-forgotten password?



Why have that password reset at all, if it doesn’t allow access to existing protected notes? That password reset mechanism reset allows you to create new locked notes, so it avoids permanently locking out all notes app usage forever, if the old unique password was forgotten. But it’s not an override that allows you (or an attacker) to access the notes data.
In more recent versions, Apple also allows selecting a different encryption scheme, where Apple will use the device password as the notes password. This alternative choice reduces the number of passwords needed, but also means anybody with the device passcode also has access to the locked notes, as some people will share their device passcodes with (for instance) their grandkids.