Place the cubed potatoes in a saucepan, cover with water, and bring to a boil. Cook until tender, about 15 minutes. Drain and return to the pan.
Add the butter, milk, salt, and pepper to the potatoes. Mash until smooth and set aside.
Heat a large skillet over medium heat. Add the ground beef and cook until browned, breaking it up as it cooks.
Stir in the onion, carrots, and garlic. Cook for 5 minutes until the vegetables soften.
Mix in the tomato paste, beef broth, thyme, and frozen peas. Simmer for 8 minutes until the mixture thickens slightly.
Transfer the beef and vegetable mixture to a baking dish. Spread the mashed potatoes evenly over the top.
Bake at 400°F for 20 minutes until the potato topping is lightly golden.