Preheat the oven to 400°F (200°C). Wrap the garlic heads in foil and roast for about 30-35 minutes until soft.
In a soup pot, heat 1 tablespoon of oil and sauté the onion and chopped garlic until translucent. Add the broth, white beans, rosemary, and lemon juice. Bring to a boil and simmer for 10 minutes.
Once the roasted garlic is cool, squeeze the cloves into the soup. Stir well and season with salt and pepper to taste.
Serve hot, garnished with grated parmigiano reggiano if desired.
Notes
This soup can be made ahead of time and reheated. It also freezes well.