SEOUL—South Korean President Yoon Suk Yeol eluded impeachment on Saturday, as allied lawmakers walked out before a vote and stalled efforts to punish him for declaring martial law earlier this week.