Basically, as more people upload photos of a location on Google, the higher the chances of that location being a PokeStop or a Gym. Lastly, many other locations were suggestions submitted by Ingress players. The more popular suggested locations would then become a Gym.