As said, the VFD will look for a higher voltage than you have, and your 2HP is a lot more power than you might think it is so it will consume a battery faster than you think. Let's look at an example, assuming you have a 230V VFD.
To run a 230V 3 phase AC motor rated 2HP, you first will need 30 12
volt batteries in series.
2HP 230V 3 phase will be roughly 6.8A Full Load.
Assume 1/2 hour of mowing time, on the surface that looks like you
only need 3.4 amp-hours of battery power.
But it doesn't really work that way, because to keep the motor at full speed, you must give it full voltage. Yet as soon as you start to discharge, the voltage is dropping as the batteries drain. Without going too deep into it, you run into a chase scenario wherein you have to keep adding cells in parallel to increase storage capacity, but that adds weight, which drains them faster, which requires more batteries.
So you might be able to START it with 30 x 5AH 12V motorcycle batteries that weight 2lbs each, but it will likely only run at full speed for 2 minutes. If you go with a 55AH battery so you can run for 20 minutes, each battery now weights 40lbs, so you have 1200lbs of batteries on your mover!!! Now because your riding mower has to carry the batteries too, the 2HP motor can't move them and you and the mower, so you have to go to a 20HP motor, and the process starts over. Next thing you know, you are attaching a mower blade to your Prius!