The Fremont factory built the world’s first truly modern EV. A part of it is now being converted into a humanoid robot plant.