Whenever I've tried to use Time Machine over the network, to a NAS or even to another Mac, it craps out after a few months and says the backups are invalid and asks to start again from scratch.
Advice seems to be 'only use it with external drives' and then every time you plug the drive in it wants the password.
For the last several years I've very happily used it over SMB to ZFS (with autosnaps) for this very reason, and wrote an AppleScript to automatically "verify" it every week or so.
Once or twice a year it gives a verify error (i imagine this is because a plug gets pulled halfway through a backup on one side or the other), and I just have to go find the last verified date, zfs rollback, and then re-verify. Afterwards it picks up where I left off, and the historical backups are preserved.
Wish it didn't require this extra effort in the first place, but much better than having to nuke and pave every time.
Even better, it's working great over Tailscale so I can even use it remotely. Only big hiccup I ran into was figuring out some ZFS setting about quota vs refquota (something like that) to have the Time Machine's (artificial) space limit match the ZFS quota so that Time Machine would prune the oldest backups appropriately (otherwise the ZFS snapshots took up an unpredictable amount of space and Time Machine would unexpectedly get out of space errors before hitting its space limit).
I used to get that constantly when I was backing up to a Synology NAS. I switched to an ASUSTOR AsusFlash NAS connecting over SMB and haven't had a single problem since. New NAS is M.2 based and can easily saturate its 10gbe link.
Side note, Synology is dead to me. Synology became consumer hostile with trying to force you to use their drives, they don't have good small scale M.2 options(at least as of last year when I upgraded), and their stuff doesn't even work for me reliably.
Advice seems to be 'only use it with external drives' and then every time you plug the drive in it wants the password.