Shelter on the Moon differs very little from that on the Overworld except that it requires machinery to live in it long term. Many terrain features and naturally occurring structures allow for more time to be devoted to safety and habitability as opposed to construction.
NPC villages will generate on the moon as normal, however, the houses are different. They are grey and dome-shaped. The villagers also have a large, blue, bulbous head. As of now, they can't trade.
Craters provide a unique location for a more permanent shelter that is less imposing on the landscape. By placing blocks flush with the Moon's surface, the craters can provide a pre-dug shelter that is a few blocks in depth and well hidden. The depth also offers some protection against fallen meteors. Meteors rarely penetrate deeper than two blocks and keeping your oxygen equipment underground keep it safe from both impacts and creeper explosions.