I am guessing you mean a dyed pet?
If so, you need to buy dye kits from either the black market or from other users. Dye kits go for between 2mil-11mil depending on the color and you use them on already hatched pets.
Oh, and if you paint eggs, they are no longer hatchable.