It's legal for two people to exchange sex for money.
But then there are some added technicalities: two or more women cannot share a property to use for sex work (because that becomes a brothel); people cannot control sex workers (pimping is illegal); it's illegal to pay a trafficked worker for sex; etc etc.
These have been added over the years, and so we have a confusing situation. People don't really know what is or isn't legal.
With this kind of stuff law should be clear because it's mostly about telling society what is acceptable. That guides people into making less unacceptable choices. (EG: Curb crawling: "Pay women to have sex is okay; but don't approach women on the street in your car and ask if they're prostitutes". That law should be about guiding people to use advertised prostitutes, but it's used to clamp down on all prostitution.)