Yahya Sinwar’s appointment as the top leader of Hamas formalizes a role he assumed in the early hours of Oct. 7, when the terrorist group attacked Israel.