I had a similar issue with my Ubuntu server before converting it to Unraid as remote connections would not render correctly without a monitor connection
My solution was to simply buy a dummy plug that I would attach to the graphics card output to trick the computer into thinking it was attached to a monitor; it's a quick-and-dirty solution that does the job just fine
This was the one I bought (it was for an older machine that didn't have HDMI or DisplayPort, but those variants exist too):
https://www.amazon.com/gp/product/B07YLR93N4