GDPR applies to companies operating in the EU, not every single entity on the internet
It applies to every single public entity on the internet that holds data of EU citizens. No matter which country they're located in.
AFAIK, this world-wide nature of the GDPR is pretty unique and quite contentious.
The GDPR includes exceptions for private purposes but hosting a lemmy instance with public signups is most certainly not intended to be of private nature, so the GDPR does apply.
I can't comment on whether that means the right to be forgotten needs to be exercised by federated instances, I just want to set the record straight here.