My guess is that some herdsmen discovered they could give raw milk without making cheese out of it to toddlers, and stopped giving it as the kids developed intolerance - until at a point the kids didn't develop intolerance, and gained an evolutionary advantage. Un roi sans divertissement est un homme plein de misères
Evolution in action !
Funnier yet: most probably co-evolution.
So, in societies where milk was really the only thing available during some periods, being lactose intolerant was strongly selected against (like: you might die).