Toyota Motor Corp. agreed to buy a stake in Mazda Motor Corp. and jointly build a $1.6 billion plant in the U.S. Asia’s largest