Mountains are usually present in Fantasy stories for two purposes.
Firstly, they act as borders. Often mountains will mark the edge of the portion of the world with which the characters are concerned, and no one knows (or cares) what lays beyond them. They also often act as hedges between diferent countries. For whatever reason, the actual mountains often do not seem to belong to either of the kindoms on either side, and are frequently the territory of monsters or mysterious peoples.
Seccondly they frequently act as trials for the characters on their journey. The most difficult portions of the story frequently take place in mountains. Either cossing them and fighting the forces of nature is the struggle, or (more likely) they must face an enemy within them before they are able to get to the other side. Dragons of course are the usual mountain dwelling foe. Usually mountains stand over caves, which can be another of their trials. Treasure, also, is frequently hidden in mountains, and searching them is usually difficult.
In either case, mountains nearly always represent mysterious, wild lands which contain many mysteries. Usually 'civilized' people are not pictured living in them.