Which is basically what we do in NZ. We have Road User Charges (RUC) that you buy in advance. We put road tax on petrol, so petrol vehicles don't pay RUCs. But no road tax on diesel, because tractors and other machinery that doesn't go on public roads. So we just extend the same RUC system for diesel vehicles to EVs.
(But not yet because we were incentivising EV up take. RUCs for EVs will be required in 2024 I believe.)