Gold being heavy has a tendency to sink while lighter elements want to float. Deep upwellings from impacts, mountain building to volcanic eruptions brings gold upwards. My theory is if an impact created the circle of fire*, deeper stuff came up if it was down there in the first place. Where there is quartz there is sometimes gold but so is fool's gold. There are probably better theories about goldmining and origins of gold. Then there could be rare asteroids.
* some think the circle of fire is a massive impact site where the moon came from, composed of Earth+Theo when rock debris was pushed into orbit.