From Sigmund Freud, "Fetishism" --
It is not true that the child emerges from his experience of seeing the female parts with an unchanged belief in the woman having a phallus. He retains this belief but he also gives it up; during the conflict between the deadweight of the unwelcome perception and the force of the opposite wish, a compromise is constructed such as is only possible in the realm of unconscious modes of thought -- by the primary processes. In the world of psychological reality the woman still has a penis in spite of all, but this penis is no longer the same as it once was.Something else has taken its place, has been appointed its successor, so to speak, and now absorbs all the interest which formerly belonged to the penis. But this interest undergoes yet another very strong reinforcement, because the horror of castration sets up a sort of permanent memorial to itself by creating this substitute. Aversion from the real female genitals, which is never lacking in any fetishist, also remains as an indelible stigma of the repression that has taken place. One can now see what the fetish achieves and how it is enabled to persist. It remains a token of triumph over the threat of castration and a safeguard against it.