macOS recovery
macOS recovery
You're trying to reset your Mac to factory defaults after a recovery. The previous user's password remains, but reinstalling the OS should clear it. Wiping the drive with Disk Utility and then reinstalling will likely restore everything, though you may need to reconfigure settings afterward.
On the disk utility wipe, if you notice two partitions where one is significantly bigger than the other, it likely means you have a disk image of the operating system that can be used for reinstallation. Otherwise, it would be better to take it to an Apple store.
After booting into recovery and using disk utility, you’ll notice two partitions: the main drive and a recovery partition. You can format the main drive carefully, ensuring it uses the right filesystem, and then reinstall MacOS there. Also, create an install drive—details are available at the provided link.