I observed through my field study to search for groundwater by electric exploration that the groundwater located near the mountains is fresh, unlike the groundwater located far from the mountains.
I practice a lot of mountaineering, when I was young, and never have problems drinking fresh water in mountains. But some mountains have minerals, and some of them can be heavy metals.
As the colleagues afore talked, it will depend on the geological features of your study area, but the hydrological features could have an influence too. If for some reason the residence time of the groundwater is large, probably the groundwater will get "mineralized", probably with a high content of some elements found in the mineralogy of the aquifer. So, in this case, the predominant lithotype of the study region could be anyone (supracrustal rocks, granites, basalts, etc) and not necessarily the presence of some brines deposits, which is a very common reason for high salinity of groundwater.
In such a system normally there is no influence of anthropogenic sources, however, there is a possibility that a part of the Mg2+, Ca2+, and SO42- originates from mineral dissolution, ion exchange, and water-rock interaction.
A key point is going to be what you mean by "near" mountains. The closer you are to high-elevation, surface, drainage divides, the less likely you are to have water with high total dissolved solids (TDS). This is especially true when speaking of groundwater that is emerging in springs and into streams' baseflow. But that isn't an issue of near, that is in the mountains.
In the arid western U.S. there is inter-basin flow. In deep ground water one can encounter very high TDS at the edges of mountain ranges, and under mountain ranges.
Another source of high TDS to keep in mind is hydrothermal phenomena. In areas where there is high heat-flow, or where faults allow for deep circulation of groundwater that then returns to the surface, the TDS of ground water can become very high.
There are also issues with sulfide minerals and the pH of groundwater.
The foregoing, along with what previous posters have mentioned, mean that the answer to the question you posed is "no". Groundwater near mountains is not always fresh, not even groundwater that comes to the surface.
The second part of your question might be rephrased as "why does groundwater near mountains tend to be fresh?" I think that the primary answer to that question relates to the residency times of groundwater. Mountains tend to be areas of higher precipitation due to orographic effects. Thus, they tend to be areas of higher groundwater recharge. Therefore, most groundwater coming to the surface has had a relatively short residency time in the ground and this equates to little time to dissolve solids. Just remember that these are all generalizations. There will always be exceptions.
Ground water of foothill and mountain areas. The greatest interest for water supply in the foothills is represented by the waters of the removal cones. An outflow cone is an accumulation of loose material (pebbles, sand, gravel) in the mouth of mountain streams, in places where they exit to the plain. The thickness of coarse-grained deposits in the removal cone is huge (from several hundred meters to 2-3 km).
Fresh ground water is distributed in the head part of the removal cones (feeding area), which is composed of large-block material and in areas of intensive wedging. Their reserves are considerable.
In mountainous areas, there is less underground water than in the foothills. Powerful flows of fresh ground water are found only in alluvial deposits of mountain river valleys.
In General, appreciating the role of ground water as a source of drinking water supply, it should be emphasized that ground water creates great difficulties in the production of construction works (fill pits, trenches, etc.) and prevents the normal operation of various buildings and structures. In the practice of construction, it is often necessary to take measures to combat ground water.
Same situation here in BCS Mexico. Depending on rock type, but usually there is more rain in the mountains, and groundwater is "young" therefore water tend to be fresh. However, depending on the mineralization of rocks and/or anthropogenic activity (like mining and farming, among others), water can have high concentrations of metals and increased salinity.
A lot of factors account for the quality of water in an area: this factors include:
topology, geology, elevation, environmental conditions, water residence times in the rock, groundwater flow path, infiltration and anthropogenic activities. Depending on these factors water from mountainous area could be soft or not.