Where would you find an engine? It's not like a lot of people are parting out CRF250X & R motorcycles. Late model used CRF's sell for as much, or more than a new CBR250R. Doing an engine swap would not be cheap, even if you could source an engine. It wouldn't be a direct swap, so there would be a fair amount of fabrication work.
Or you could put your money toward something like a CBR500R.