I have seen this issue sometimes, not only with RetroPie but with other operating systems as well. I don't know the cause. After I choose to reinstall the OS, it works. A bad card reader or a faulty SD card, I believe, can cause a similar issue.
Make sure that you have the latest version of PI imager You can install also the RetroPie over the Network: https://www.raspberrypi.com/documentation/computers/getting-started.html#install-over-the-network