On the origin of mascons and moonquakes