It's not, it's only illegal to misrepresent the mileage when you come to sell the car...you could stop the mileage on 0 if you wanted and still pass every MOT.
You'd only get in trouble if you tried to tell people that's how many miles it's done...hence why all main car dealships you go into...