Yes, it’s possible.
When an anonymous user is created they have an email address in your domain with anon prepended, like this: anon.community.examplesite.com
— when creating a group you should be able to add that domain to the automatic membership settings.