TJX, the company behind T. J. Maxx, Marshalls and other discount stores, said that it had named its president, Ernie Herrman, chief executive.