Why this one matters
When your library lives on your own Mac, nobody else is keeping a copy. A failed drive, a theft or a spilled coffee can take it, and so can an accidental delete. Sync services like iCloud mirror deletions: remove a photo on one device and it disappears from the others. That makes them useful, but they are not a backup. A backup is a separate copy that doesn't change when you do.
The plan: three copies, two kinds of storage, one elsewhere
The usual rule is called 3-2-1. Keep three copies of what matters: the original and two backups. Put them on two different kinds of storage, such as your Mac's drive and an external drive. Keep one of them somewhere else, so a fire or a burglary can't reach all of them. Here is the short version of how to do that.
Step 1: Time Machine to an external drive
Time Machine is built into your Mac. Plug in an external drive, open System Settings → General → Time Machine, choose Add Backup Disk, and pick the drive. From then on it backs up quietly in the background, and your photo and music folders are included unless you exclude them. Leave the drive plugged in, or reconnect it regularly.
Step 2: One copy somewhere else
A second drive that lives at work or at a relative's house is the simplest offsite copy: swap it with the one at home every few weeks. An encrypted cloud backup service such as Backblaze or Arq is the hands-off option. It backs up folders without browsing or processing them, and costs a fraction of a photo subscription. A network-attached storage device at home adds redundancy, but it shares your home's risks, so it doesn't count as the offsite copy.
Step 3: Save your edits into the files
Raza Photos and Raza Songs keep the edits you make on your phone in a local database until you save them. Choose Save Metadata from the Library menu on the Mac, and the changes are written into your original files, in open standards other apps can read. That makes your files, which are what you back up, the complete record of your organisation work. How saving works →
Step 4: Check that it works
A backup you've never restored from is a hope. Once in a while, open the backup and restore a single photo or song to the desktop and make sure it opens. In Time Machine, check that the latest backup date is recent. Do this every few months, and after you change drives.
What not to rely on
A single external drive that is always plugged in is one power surge away from being a second casualty. iCloud Photos as your only copy means a mistaken delete reaches everything. A RAID or NAS on its own is redundancy, not a backup: it protects against a disk dying, not against deleting the wrong folder or ransomware. Use them alongside the plan above, not instead of it.