It can be a trimming issue or it can just plain be the horse's conformation--or not really "conformation" as such but just the way the horse's tendons/ligaments work. I had a Morgan gelding that had that twisting motion in his hind legs, only in his case it was in his hocks, not his fetlocks. He never had any problems because of it--he stayed sound all his life, but as a halter horse it is something that would have counted against him in strong competition.
If a mature horse doesn't do it and then suddenly starts I would have to think either it's a trimming problem, an injury (especially if it's only one leg) or perhaps an age related issue where years of work, wear & tear have caused some weakness in the tendons/ligaments, allowing the leg(s) to twist now in ways they didn't when the horse was young.
Besides my Morgan gelding I've seen other horses that twist the same way, usually in the hocks (as the horse puts weight on the hind leg the hocks rotate outward) but a few in the ankle. I saw one that was really bad for twisting in the hocks, others do it in a very minor amount. From observing in in several breeding animals and noting that some offspring of the horses had it and others didn't I have to think that the condition is hereditary some of the time--some offspring will have the same trait, others won't.