So if my intention is to edit for screen viewing only and set the color space to Display P3 on my mac, do I need to go to the monitor and select a color mode and what about the color space when opening photo in lightroom?
Your Mac ships with a pre-selected monitor profile, which is most probably Display P3. If so, you can leave it alone.
You can look at Lightroom and see what color space it is set to. Unless you have changed it, it will be Adobe's recommended color space for Lightroom.
My guess is that you will see more of a change to your image by adjusting (or failing to adjust) the
brightness of your monitor, than you will by making changes to the color space. You likely want to choose a middle-of-the-road brightness setting, to match what we hope will be that of the average viewer's device.
For example, if you perform all your edits in a dimly lit room and you set the monitor brightness way down to avoid eyestrain, then when the average person views your photos, they will look too bright. (You would have lightened your images while editing, to make them look normal on your overly dark monitor)
Conversely, if you edit your images in a brightly lit room and you turn your monitor brightness way up to accommodate, then when the average person views your work on their device, the images will look too dark (You would have darkened your images to make them look normal on your overly bright monitor.)
And if I want to edit because I want to print my image and I set the color space to Adobe RGB on my mac, do I switch the color mode on the monitor to Adobe RGB as well ?
Color-managed fine art printing, where what you see on your monitor matches what you see when you view your prints under calibrated lighting... requires some time and expense. There's a learning curve. You can learn a lot by studying online resources.
Or you can simply farm out your work to a printer service that has already tackled the issues. They can tell you how to configure your system to accord with
their workflow. They will tell you what profile, brightness and color temperature to set your monitor, and what
ICC profile to use when editing/soft-proofing/printing for their printer/ink/paper - and what color temperature lamp they use to judge prints.
I guess I am not sure if I should change the color space on the mac only or on the monitor only or both to get an accurate color for both viewing and printing.
For printing, we need a monitor calibrated to the correct white point, brightness and color space. Then we need a printer profile for the printer/ink/paper we will use, and our editor needs to let us make corrections while soft-proofing the image under that profile. And we need to print with that profile included in the printing workflow.
You might want to tackle the fewer challenges of editing for the web before taking up printing.