People with a compromised immune system are a good setting for evolving new variante of coronavirus. They stay sick for a long time (meaning more viral replication and more opportunities for mutation) and they apply a weak immune response which while not sufficient to wipe out the disease, provides selective pressure that rewards immune evasion.
There's a common antivaxxer myth that vaccines promote the creation of new variants and that we would be better off without vaccination. I think it's very important to emphasize that is not the case.