Preheat your oven to 350°F (175°C). Lightly grease a 9x13 inch baking dish. Cook the elbow macaroni according to package directions until it is just al dente. Drain the pasta well and set it aside.
In a large saucepan or Dutch oven, melt the butter over medium heat. Whisk in the flour and cook for about one minute, stirring constantly, to form a smooth paste (a roux).
Gradually pour in the milk while whisking continuously to prevent lumps. Continue to cook, stirring often, until the sauce thickens enough to coat the back of a spoon, about 5 to 7 minutes.
Remove the saucepan from the heat. Stir in the cubed process cheese, grated cheddar, and half of the Parmesan cheese (1/2 cup or 50 g). Continue stirring until the cheeses are completely melted and the sauce is smooth.
Stir the Dijon mustard, salt, and pepper into the cheese sauce.
Add the cooked macaroni and the diced ham to the saucepan with the cheese sauce. Stir everything together until the pasta and ham are evenly coated.
Pour the mixture into your prepared baking dish and spread it into an even layer. Sprinkle the remaining Parmesan cheese (1/2 cup or 50 g) over the top.
Bake for 25 to 30 minutes, or until the sauce is bubbling around the edges and the top is golden brown. For food safety, ensure the center of the casserole reaches an internal temperature of 165°F (74°C).
Let the mac and cheese rest for 5 to 10 minutes before serving. This allows the sauce to set and thicken slightly.