The title of your question mentions "Backing up Photos", but If I understand you correctly, you are not asking about a backup (creating a safety copy of your Photos Library, that is never used, unless in an emergency, when you have to recover lost or damaged photos), but you want to have the working copy of your Photos library on a NAS, to be shared on your local network.
As TD explained, sharing a Photos library on a local network is not supported. This is clearly stated by Apple - see: Move your Photos library to save space on your Mac – Apple Support
"To prevent data loss, Apple doesn't recommend storing photo libraries on external storage devices like SD cards and USB flash drives, or drives that are shared on a network."
However, you can share your library easily in iCloud as an iCloud Photos Library between all your devices. Then the central copy will reside in iCloud, mirrored on all devices (Use iCloud Photos to store photos in iCloud - Apple Support). But you will still need to make regular backup copies on a local volume (for example with tIme Machine) to be able to recover damaged or accidentally deleted photos (Back up the library in Photos on Mac - Apple Support).