See the following Apple articles:
If you think your Apple ID has been compromised
If you think your Apple ID has been compromised - Apple Support
Recognize and avoid phishing messages, phony support calls, and other scams
Recognize and avoid phishing messages, phony support calls, and other scams - Apple Support
-----
On my Mac I use SpamSieve, SpamSieve is a paid application.
SpamSieve is a powerful spam filtering to the e-mail client on your Mac, see:.
https://c-command.com/spamsieve/
On the Mac, SpamSieve allows you to block spammers.
As a result, you will not get spam on the iPhone or other iDevice.
From a spammer after you add the email address to the blacklist, the email address will be permanently blocked.
For several spammers, each time you have to add their email address separately to the blacklist in SpamSieve.