It doesn't work.
By default you have complete ownership of all works you create. What that license link is doing is granting an additional license to the comment. (In this case likely the only available license.)
This means that people can choose to use the terms in this license rather than their "default" rights to the work (such as fair use which is which most AI companies are claiming). It can't take away any of their default privileges.
I should add that there is one approach that could be taken here. Take this with a huge grain of salt because I am not a lawyer.
When you are posting on Lemmy you are likely granting an implicit license to Lemmy server operators to distribute your work. Basically because you understand that posting a public comment on Lemmy will make it available on your and other Lemmy servers it is assumed that it is ok to do that.
In other words you can't write a story, post it on Lemmy, then sue every Lemmy instance that federated the comment and made it publicly available. That would be ridiculous.
There is a possible legal argument that twists this implicit grant to include AI training. Maybe you could have a disclaimer that this wasn't the case. I don't know how you would need to word this and if it would actually change anything. But I would talk to a lawyer.