Classical conditioning, made famous by Ivan Pavlov's experimentation with the conditioning of a dog, is included in the branch of psychology named behavior modification/behaviorism. In this type of conditioning, one must be sure that two things exist: a naturally occurring reflex and a environmental stimulus. For example, in Pavlov's experiment, the dog salivating is the naturally occurring reflex and the environmental stimulus is the ringing of the bell.
Classical conditioning has been proven to exist as a basis for phobias. This occurs through the process of stimulus generalization. In this process, a person has a bad experience with something (the environmental stimulus) which plays upon their own fear (the naturally occurring reflex).
For example, if a child (who does not know how to swim) is thrown into a pool, he or she may develop a fear of water. Given that their fear of water is based upon them being thrown into the water constitutes classical conditioning. It was the child's fear (a naturally occurring reflex) and the water (the environmental stimulus) which caused the fear of water.
This said, there are some unfounded phobias which exist in some people given they have never experienced a situation where classical conditioning took place. Their fears simply exist for no apparent reason at all.
Classical conditioning can also be used to treat phobias in a process known as desensitization. In this process, the person with the phobia is exposed to the thing of which they are afraid. The psychologist (or doctor) then teaches the patient how to reduce his or her anxiety (typically through breathing and/or relaxation exercises).