Calculate all cyclic subgroups of a group under multiplication of modulo n (group theory)
Two things to consider:


pow is an overkill. To calculate the subgroup, I'd continuously multiply a power by the generator:

subgroup = [1]
power = generator
while power != 1:
    subgroup.append(power)
    power = (generator * power) % modulus


BTW, now you don't have to special case a trivial subgroup.
I would also strike out calculated powers from the list of candidate generators (that is, coprimes). This way you'd avoid recalculating the same subgroup over and over again.