From what I understand the normal passwords that can be set on shares is not sufficient for you (because it does not ask for the password if you are not using the particular share).
There is also Passwords - Apps - App Store - Nextcloud - a password safe (where you can add notes and other properties), but I do not use that so I do not know when exactly it asks for the password, but you can try if that fits your needs.
Personally I would never ever lend my computer if I am not sitting next to the person using my computer - never.