Preheat oven to 375°F (190°C). Boil pasta until just al dente (1-2 minutes less than package directions).
Brown ground beef in a large skillet over medium heat. Add onions and garlic when beef is halfway cooked. Stir in chili powder and cumin. Add tomatoes and beans.
Melt butter in a saucepan over medium heat. Whisk in flour and cook for 1 minute. Gradually add milk, whisking constantly. Add 2 cups of cheese, stirring until melted.
Combine pasta, chili, and cheese sauce in a large baking dish. Top with remaining cheese. Bake for 20-25 minutes until bubbly and golden.