That’s odd. Have you power cycled both the Apple TV and your router? I would put money on the Apple TV, myself, but either way, AirPlay 2 should not be disconnecting while it is playing. Apple does have a time out, I think, when not sending/receiving anything, but that certainly doesn’t sound like what you’re experiencing.
If power cycling these other devices doesn’t help, I would recommend that you submit a system diagnostic within 10 minutes of experiencing this problem, and call Sonos Support to discuss it. But don’t post the resulting diagnostic number here, they get sensitive about GDPR.
There may be information included in the diagnostic that will help Sonos pinpoint the issue and help you find a solution.
When you speak directly to the Support staff, they have tools at their disposal that will allow them to give you advice specific to your network and Sonos system.