Cook macaroni according to package directions; drain.
In a medium pot, heat butter and saute onions. Add milk, flour, salt and pepper. Bring to rolling boil. Slowly add cheddar cheese; stirring while adding. After cheddar cheese had dissolved, add the mozzarella cheese, stirring while adding.
Add macaroni directly to the cheese mixture in the pot. Pour into a large, greased lasagna pan. Bake for 30 minutes or until top is bubbly and golden brown.