Jesus said:
"For as Jonas was three days and three nights in the whale's belly; so
shall the Son of man be three days and three nights in the heart of
the earth." (Matthew 12:40)
A "beast," as the Bible likes to call an animal, represents a nation, government, or kingdom in prophecy; and the fish/whale which swallowed Jonah is no exception.
For example:
"Thus he said, The fourth beast shall be the fourth kingdom upon
earth, which shall be diverse from all kingdoms, and shall devour the
whole earth, and shall tread it down, and break it in pieces." (Daniel
7:23)
Jesus makes a direct equation between the belly of the fish and "heart of the earth." At the time of Christ, the kingdom which would most fittingly represent the "heart of the earth" was that of the Roman kingdom. It was the most powerful nation in the known world at that time, and it ruled over all of Israel.
To be in the belly of the whale/fish (a beast of the sea) was to be entirely within its power--virtually to the point of helplessness. Jonah was unable to extricate himself from the belly of the fish. In like manner, Jesus came under the power of the Roman government at his arrest in the Garden of Gethsemane.
Jonah was in the whale's belly for three days; and Jesus was within the power of the Romans for three days. Jesus entered Roman control at his arrest on Thursday night, was crucified by the Romans on Friday, and he lay entombed under seal and guarded by a company of Roman soldiers until the Sabbath was past. This totals three days and three nights:
Thursday night, Friday = 1 full day ⇘
Friday night, Sabbath = 1 full day ⇒ 3 full days
Sabbath night, Sunday = 1 full day ⇗
This three days and three nights fulfilled Jesus' prophecy, for he had specified:
"For as Jonas was three days and three nights in the whale's belly; so
shall the Son of man be three days and three nights in the heart of
the earth." (Matthew 12:40)
As the sacrifice of Jonah by throwing him into the sea saved all of the occupants of the ship, so the sacrifice of Jesus was to provide a means of salvation to all on earth. Unwittingly and unwillingly, Jonah became a type for Christ.
The prophecy seems so clear and the correlation between Jonah's experience with what Jesus predicted would happen to himself so well paralleled, as to give us confidence in the interpretation of the symbols for the prophecy.
The fish represented the Roman kingdom; and its unwilling occupant represented our Sin-bearer, who likewise desired that "this cup" (this experience) should pass from him (see Matthew 26:39,42; Mark 14:26; Luke 22:42; cf. Jonah 1:10).