Read Eliyahu HaNavi (Sefaria) for the surrounding biblical/liturgical context.
Elijah (אֵלִיָּהוּ, "my God is YHVH") is the 9th-century BCE prophet who confronts King Ahab and his Phoenician wife Jezebel over the worship of Baal in the northern kingdom of Israel. The dramatic showdown on Mount Carmel (1 Kings 18), the fleeing to the cave at Horeb where God speaks in a "thin small voice" (1 Kings 19), and the ascent to heaven in a chariot of fire (2 Kings 2) are among the most cinematic stories in the Tanakh.
The crucial detail: Elijah doesn't die. The Tanakh is explicit (2 Kings 2:11), he is taken up in a whirlwind, alive. This means he is, in some sense, still here. The folk tradition develops accordingly: Elijah appears at moments of need (in disguises, as a beggar, as a stranger), he is present at every circumcision, he visits Jewish homes on Friday nights, he is the herald who will announce the Messiah's arrival.
The end of Shabbat is the moment Jewish hope re-engages with secular time. For 25 hours the world has been close to its perfected state; now we return to the work-week. Eliyahu HaNavi is the song that says: but you don't have to stay in the imperfect state. Things can change. The redeemer is on his way.
The Talmud (Eruvin 43b) discusses why Elijah cannot come on Shabbat itself, because his arrival would impose obligations (prepare the Temple, gather the people) that violate Shabbat rest. So the people wait for Saturday night, and the first thing they do is sing him in.