In fact, in a bathroom, I'd use pressure treated plywood as your underlayment, and paint the cut edges with end cut preservative.
You should also know the difference between "plywood" and "underlayment" that looks just like plywood. The difference is that plywood is allowed to have voids of a certain size or larger in the interior plies. In underlayment, these voids have to be smaller than a certain size or filled with water putty. Otherwise, the underlayment can have "soft spots" in it that can result in depressions in the flooring.
The two best underlayments I know of are fir plywood underlayment or Baltic Birch furniture grade plywood. The latter is surprisingly inexpensive cuz it comes from Russia, and the ruble is cheap compared to the US dollar, even now. If I were building a house or addition, I'd use the baltic birch plywood as underlayment cuz it's made from a hardwood, so it's both strong and, more importantly, hard. I install vinyl composition floor tiles in all the apartments in my building, and having a hard and strong underlayment means that the tiles won't dent when you put something heavy on the floor. So, any kind of resilient flooring, like VCT tiles, sheet vinyl or even real linoleum is going to stand up better with a hard and strong backing as can be provided by the birch.
Fir plywood underlayment would be the second choice. I don't think Baltic Birch comes in an underlayment, only a plywood, but I'd still use it as underlayment.