"The temperature for Lead deposits to form tend to be favourable around the spark plugs (as the whole mixture is quite cool before the flame starts to propagate) and on the exhaust valve stem (as the mixture cools after combustion). The problem is that the deposits are electrically conductive, which shorts out the spark plug - and corrosive, which can start to attack the metal of the valve stems."
The theory that leaded gas prevents micro-weld induced valve abrasion has not been verified in controlled tests. The final report from the EPA's Valve Seat Recession Working Group found no evidence that leaded gas reduces engine wear under any but the most extreme operating conditions:
https://archive.epa.gov/international/air/web/pdf/vsr-finald...
"In real world conditions, virtually no evidence of excessive valve wear has been found in vehicle or engine operation in normal everyday use, and several studies that monitored vehicles in actual daily service in countries that eliminated lead found no excessive valve wear."