In entering into Jerusalem on a donkey, Jesus was publicly declaring himself to be the "son of David" and the rightful king of Israel. But there’s an even bigger reason to connect Jesus’ entrance into Jerusalem with his claim to be king than Zachariah 9.
We know that the act of riding a mule into Jerusalem was the sign by which Solomon was proclaimed king of Israel. This event is found in 1 Kings 1. The ride on David’s mule is there emphasized, being repeated three times.
In 1 Kings 1 David's eldest son, Adonijah, takes advantage of his father’s weakness to unite publically with his Father's men, declaring his intentions to the throne.
But some are troubled by his plan. Bathsheba being one of them. She goes to David and reminds him of the promise he made to her and her son.
David instructs them on what to do.
set Solomon my son on my own mule and take him down to the Gihon.
There have Zadok the priest and Nathan the prophet anoint him king
over Israel. Blow the trumpet and shout, ‘Long live King Solomon!’
And they do as he said.
Then they sounded the trumpet and all the people shouted, “Long live
King Solomon. And all the people went up after him, playing flutes
and rejoicing greatly, so that the ground shook with the sound.
But of course the news doesn't make everyone glad. Adonijah and his supporters flee from their feast in fear.
This is a particularly crucial event in Israel’s history. It’s Israel’s first dynastic succession. Though Saul had been the first king of Israel, he had no successor. He and his sons were killed and the rule passed to a new line of David. It’s not until Solomon’s coronation in 1 Kings 1, however, that we find David’s royal linage established. And it’s established in none other than Solomon’s ride into Jerusalem on David’s mule.
Given this events historical and symbolic importance, Its likely that it was repeated in all subsequent coronation ceremonies. In the same way George Washington’s personal decision to swear on a Bible has been repeated in all subsequent presidential inaugurations, so the riding into Jerusalem on a mule formed the basis for future coronations. Jesus, by entering Jerusalem on a donkey, appears to be acting out a royal coronation ceremony which the people recognized.
In this one act Jesus symbolically proclaimed himself the "Son of David" and the restoration of the fallen house of David. The people clearly recognized this. In each of the four Gospels they shout with joy at the coming kingdom. Their use of palm branches also pointed to Jesus as the coming King. This was how the Macabees were celebrated as they entered Jerusalem after defeating the Seleucid king.