If this weren't done, there would be risk of electricution to anyone working on wiring in the house or on the utility distribution network.
Skip to about 10 minutes into this video: https://practical.engineering/blog/2022/12/5/what-is-a-black...
Furthermore, the danger of backfeeding is if you do it in a power outage and you start to power your neighbors' houses. It'll overload your generator and create a hazardous situation for anyone working on the wires. (This is why you're supposed to install either a generator switch or interlock. I have one that only allows me to energize when my main breaker is turned off.)
It outputs at the same phase and frequency as the grid, and with a slightly higher voltage (think of a ball rolling down a slope from a higher voltage to lower voltage).
If the grid is down then it stops the inverter for a minimum safety period (some minutes iirc)