"New Mexico" was not a term invented by Americans in the wake of the Mexican-American War.The name New Mexico (or Nuevo Mexico) has been applied to the region since at least the 1590s.^1
Similarly, the name California was already in place during the Spanish colonial era, and Americans were simply adopting an established Spanish term for the region.
The territory that is now the state of Arizona actually did form a part of the territory of New Mexico for a time in the 1850s. However, when that territory was split in 1863, the region containing the existing territorial capital Santa Fe retained the name New Mexico, and the western half now became Arizona.
New Mexico was actually named by Spanish explorers during the mid 1500s. California is named because it forms part of the "Alta California" territory, under Mexican rule. Arizona's name is probably derived from a Spanish or Native American name for the area, like the others, but I have not read of a definitive source for the name.