The actual "letter of the law" is ambiguous. Kavanaugh can choose to caution either player or not and be in line with the letter of the law.
In the first phase of the incident, Veltman is confident enough to slow down his own free kick, and nudges the ball towards Rice who's turned away and is letting him go.
Veltman baits Rice into marginal contact with the ball. At no stage could the kick have legally been taken. It can be argued Veltman is doing more to delay the play than Rice.
In the second phase, Veltman disingenuously hacks Rice down while the latter is turned away. There's no attempt to use the ball. Only because Rice's contact with the ball is so minimal can one imagine, on a first viewing, that Veltman intends to use it.
Veltman's kick into Rice and the movement of his arms to appeal to the referee take place simultaneously.
The "letter of the law" is IFAB Law 12. There's probably some PGMOL guidance layered on top. Law 12 uses floating descriptions such as "delaying the restart" and "unsporting behaviour" which can apply to either Rice's or Veltman's conduct.
All the law says is that Kavanaugh is empowered to make his own judgements, both when he gives Rice a second yellow, and when he lets many other incidents pass.