Hi
Basically you can use an external USB drive. This can be an SSD (solid state drive), or a traditional "spinning" drive. SSD will be much faster. I'd suggest getting one at least twice as big as your library is now.
It has to be USB (Or thunderbolt). It can't be a network connection. Also usb memory sticks (pen drives) or SD cards (like you have in a camera) are not suitable.
When you buy an external drive, they almost always come formatted ExFAT. This is a windows format and not suitable. You can re-format the drive to APFS, or MacOS extended (neither should be case sensitive) using the disk utility app found on your mac.
Summary:
Buy a USB drive.
Reformat it to APFS or MacOS extended BEFORE you put anything on it.
Backup your library somewhere if it is not already - time machine is good.
Copy your library to the USB drive.
Check your copied library works and has all your photos
Delete the original
See
Move your Photos library to save space on your Mac – Apple Support (UK)