Even when considering the cost of their training, pay, and benefits, a fighter pilot is lot cheaper than the plane these days.
In World War Two, the pilot was much more expensive.
However, even though the economics have changed, the training has become much more lengthy and involved. It takes three years to get a fighter pilot to the point that they can safely fly and employ the airplane.
Over a decade to get to the point of being truly skilled with it.
That is part of why the USAF and USN are so short of pilots right now - they're leaving faster than they can be replaced.