When You BIOS is in Legacy Mode like Your Thread Title says, I would suggest to take Rufus or Ventoy to create a bootable USB Stick because on this Tools, You can choose the Partition Sheme between GPT for UEFI and MBR for Legacy BIOS.
Bur before this, I would suggest to try @swarfendor437's Link to reset Your BIOS Password to get Access again to it.