Are you using the same AppleID as before? Are you in the same country as before?
Are you connected to a fast and reliable Wi-Fi? On a Mac iCloud features our working best when connected to Wi-Fi, not an over a mobile hotspot. Make sure, that no third party security software or a firewall con block or intercept the access to Apple's cloud servers. Disable all antivirus software or firewalls.
if all is well, try to restart your Mac temporarily in Safe Mode. Safe mode will disable all third party system extensions and clear some caches. Use safe mode on your Mac - Apple Support
Can you now enable your shared albums? Then restart again in mode.
If you even cannot enable the shared albums in Safe Boot Mode, test in a different user account, that has not been migrated from your old Mac. if you do not have another clean account for testing, create another user account and check, if you can enable the shared albums there. if it is working in a different user account, you may have corrupted user preferences in your user library, transferred from your old Mac. Or a problem with the permissions in your home folder, that need repairing.