Yes, there are 2 ways to do that depending on whether or not you are using iCloud for photos on your phone.
If you are using iCloud with Photos on your phone -
On your new Mac, in System Settings, click on the large icon that has your name with the words "Apple ID" below your name. In the resulting window, click iCloud, then under "Apps using iCloud" turn off Photos. That way your phone's photos, which presumably are being sync'd with iCloud, will not be sync'd to your new Mac (and vice-versa).
If you are syncing your iPhone with your Mac via the Finder -
Connect your iPhone to your new Mac, open a Finder window. Then, in the left pane, select your iPhone, then in the main window headings click Photos, then UNcheck "Sync photos to your device from ..."