Matthew’s Gospel is the only one of the four that recalls Jesus saying, “Do not think I have come to abolish the law or prophets. I have come not to abolish but to fulfill.”
Matthew highlighted this saying of Jesus because it sums up Matthew’s reason for sitting down to write a new Gospel. After all, Mark had already written a Gospel.
Matthew was prompted to write by something the Pharisees were telling Jews who had become Christians. Being sticklers for being kosher, they were telling those Christians that Jesus had tried to abolish the Law and the Prophets.They said Jesus did that by eating with unclean gentiles. They said there was no way anyone could remain Jewish if they didn't observe kosher rules which came from the Law and the Prophets.
Matthew’s Gospel then went into detail demonstrating ways in which Jesus, rather than doing away with the old rules, improved on them. Like he quoted Jesus as telling us, not only should we avoid adultery, we should also avoid harboring lustful thoughts; Not only should we avoid killing others, we should avoid hating them. It’s like the teachings of Moses were primary school lessons, while Jesus was our professor for excellent graduate courses.