Board Thread:Questions and Answers/@comment-679780-20170307200224/@comment-31689608-20170407153950

I believe that it has tiny little wiring woven into the fabric that responds to electrical stimuli and translates it into movement. I also believe that the gem allows eggman to control the doll remotely.

So the tails doll isn't a "possessed demon doll" or anything, it's just a stuffed animal RC toy.