These missions returned over 380 kg of lunar rocks , which have been used to develop a geological understanding of the Moon's origins, the formation of its internal structure , and its subsequent history .