Replacing sealed Pb battery with car battery
After combining them 2p2s, you have a 24V, 18Ah battery pack. Your best bet is to replace with something very similar, say 15-25Ah @ 24V. I would use AGM batteries. I don't think it matters very much if the batteries are advertised as starting batteries or deep cycle. As long as they are AGM. AGM are a lot safer than flooded lead acid for areas where people are working all the time. Flooded batteries can out-gas hydrogen, and they can break or tip and spill. In theory, the hydrogen can accumulate and eventually ignite causing a fire or explosion.

There is a very wide selection of 6 and 12V (and even 2V) AGM lead acid batteries available from a wide variety of sources. Shipping can be expensive, though.

If you use two regular car batteries, there are a few things that could go wrong or that you might want to be on the lookout for. First, maybe the charger will time out because the battery capacity is much larger than what it expects. My feeling is that this is unlikely, but possible. This is mainly a function of battery capacity. Same problem could apply to AGM batteries.

Second, as mentioned previously, there is the possibility of out-gassing, spillage, etc. AGM batteries can out-gas but it is less likely.

Third, if you use a much larger battery pack, you could run into  thermal problems if you are near the high end of the load for the UPS. When designing something that is battery operated, you can run it pretty hard and let it get hot because you know that the heavy load is temporary, and that the battery will die. But if the heavy load continues for longer than the original designer anticipated, the electronics could overheat to point of failure (or thermal shutdown, if there is one).

Hopefully this will help you make a good decision about how to replace your UPS batteries. I am not trying to discourage you. I am just trying to share the things I would be watching out for.