iCloud Photos is a synchronization service. When you engage iCloud Photos on a device, then the Library on that device is kept exactly the same as the iCloud Photos Library. So, for instance, if you have new pictures on your iPhone, they will be copied to iCloud Photos Library, and then copied to the Photos Library on each of the other devices that you have connected. Photos will do its best to avoid duplicates. Photos doesn't delete pictures in Libraries, it merges them!
But there is one caveat: Some pictures transferred from a computer can be viewed in Photos but they can't be modified by Photos- you will see that they can't be edited or deleted, except by the computer. Those limited pictures usually appear in an album called "From My Mac," or something like that. Those pictures can't be transferred to iCloud and so they will deleted-- the idea being that they came from your computer so they should still be there. If you don't have any of those, don't worry. If you do have some, you can save them to Files before turning on iCloud. You will get a scary warning about this when you turn on iCloud Photos, even if it don't have any of those pictures.
But, in any case, the pictures that are in iCloud Photos now will not be affected at all.
Note that your Library will grow on your iPhone, on your Mac, and at iCloud.com to accommodate all the different pictures. Be sure you have enough room! You may need to turn on Optimize Storage when you turn on iCloud.
iCloud doesn't serve as a very good backup system. Do you use "Download Originals" on your Mac, and do you keep backups of Photos on your Mac?