Yes, both sentences are correct, but they differ slightly in focus:
"My favourite food is hamburgers and sandwiches."
This suggests that hamburgers and sandwiches are collectively considered your favorite food, treating them as one category.
"My favourite foods are hamburgers and sandwiches."
This sentence emphasizes that you have multiple favorite foods, listing hamburgers and sandwiches separately.
If you think of hamburgers and sandwiches as two separate favorites, the second sentence is slightly clearer. Both sentences work, though, and the difference is subtle!