When Matthew uses the phrase “kingdom of heaven” he means exactly the same thing as the “kingdom of God”. However, I don’t know any other context where Matthew uses “heaven” in place of “God”, and he often uses heaven to mean heaven (e.g., Matthew 3:17; 5:12,16).
Matthew is the only writer who uses “kingdom of heaven”. The phrase occurs in 31 places in the Bible, all in Matthew’s gospel. It is synonymous with “kingdom of God” which is used by the other gospel writers (as well as five times by Matthew).
It is often conjectured that Matthew was writing for a Jewish audience and in accordance with Jewish custom, in which the name of God was avoided, heaven was sometimes used as a euphemism. However, this does not explain why Matthew uses “God” 46 times in his gospel. A more likely explanation is that Matthew preferred “kingdom of heaven” to emphasise that this was a very different kingdom from what the Jews were expecting. The kingdom was to come from heaven, and was not to be based on a rebellion against Rome.