All were wondering
In their hearts
Was he perhaps
Προσδοκῶντος δὲ τοῦ λαοῦ καὶ διαλογιζομένων πάντων ἐν ταῖς καρδίαις αὐτῶν περὶ τοῦ Ἰωάνου, μή ποτε αὐτὸς εἴη ὁ Χριστός,
This question about John the Baptist being the Messiah can be found in John, chapter 1:25, where the Pharisees asked this question. Here Luke said that the people were full of expectations (Προσδοκῶντος δὲ τοῦ λαοῦ). All were questioning or wondering in their hearts concerning John (καὶ διαλογιζομένων πάντων ἐν ταῖς καρδίαις αὐτῶν περὶ τοῦ Ἰωάνου). Was he perhaps the Christ, the Messiah (μή ποτε αὐτὸς εἴη ὁ Χριστός)? In other words, the question was not explicitly stated, but only thought about. They were wondering if John the Baptist, the son of Zechariah, was the expected Messiah or Christ.
“The word of God
Came to John,
The son of Zechariah,
In the wilderness.”
ἐγένετο ῥῆμα Θεοῦ ἐπὶ Ἰωάνην τὸν Ζαχαρίου υἱὸν ἐν τῇ ἐρήμῳ.
Luke presented John like a prophet who was called like the other Israelite prophets. The word of God came or happened to John (ἐγένετο ῥῆμα Θεοῦ ἐπὶ Ἰωάνην), the son of Zechariah (τὸν Ζαχαρίου υἱὸν), in the wilderness or desert (ἐν τῇ ἐρήμῳ), just like it had come to many other ancient Jewish prophets. There should be no confusion about whom this John is because he was the son of Zechariah that was described in chapter 1. There is something similar, but not quite the same in all 4 gospel stories. In Mark, chapter 1:4, John appeared on the scene immediately after a citation from the prophet Isaiah. Matthew, chapter 3:1-2, seemed to follow Mark, since Mark began his gospel with this story. Matthew had John the Baptizer preaching in the wilderness or desert in Judea, southeast of Jerusalem and west of the Dead Sea. John, chapter 1:19, also introduced John the Baptist immediately after his prologue. Only Matthew and Luke have the infancy narratives before the introduction of John, who was central to the work of Jesus.