Disk locked after formatting
I am selling my iMac and I formatted every disk which also included startup disk and there is none. Now when I go to reinstall macOS, it shows the disk is locked. When I go to disk utility, it shows me no option of format e.g. Journal etc. It only has AFPS option.
What can I do to reinstall the OS?
In disk utility you will want to choose "View" in the upper left and then select "Show All Devices". From there you should be able to select the Internal drive at the very top of the list and select erase as you're used to.
Once you've erased the drive you can now quit Disk Utility, and go back to the Mac OS installer as you had been doing. The drive should now not be locked.