While it might seem like "with" would be the prefix, it's actually "with-" in this case. The "with" functions as a prefix indicating opposition or resistance, as seen in other words like:
* Withhold: To hold back or refuse to give
* Withdraw: To take back or move away from
* Withhold: To hold back or refuse to give
So, "withstand" means to stand against or resist something.