If this is an Intel Mac, then it sounds like that laptop may have a firmware password lock enabled. Is this what you are seeing?
Set a firmware password on your Mac - Apple Support
If so, then it may have a password unassociated with any macOS user account. If you don't know the password, then you will need to take the laptop to an Apple Store or an Apple Authorized Service Provider along with valid acceptable proof of purchase and personal ID so they can verify you are the proper owner of that Mac. I would suggest contacting the service location first to verify what they will accept as valid proof of purchase & ID. If you cannot provide acceptable proof of purchase & ID, then there is nothing you can do to remove it. It probably also indicates the internal drive is no longer working since the laptop is attempting to boot from other external media which it cannot do without entering the correct password for the firmware lock.