Lonnie Bunch, the Smithsonian’s first Black leader, will retire after nearly 40 years with the institution amid pressure over how American history is told.