There are no users on this volume to recover.
So I accidentally deleted the whole mac os partition and the only one available is the macOS Base System and Untitled in Disk Utility. When I tried reinstalling trough recovery and went trough the terms and conditions, after accepting them and being told that my drive had to be cleared before installing it came up with the error “There are no users on this volume to recover.” I restarted and it asked for my apple id that I entered but i sill got the same error afterwards.
iMac (24-inch, M1, 2021, 2 ports)