What are the conditions necessary for fixation of atmospheric nitrogen by Rhizobium

What are the conditions necessary for fixation of atmospheric nitrogen by Rhizobium. What is their role in Nitrogen-fixation?

The first essential condition for nitrogen-fixation is legume-bacteria relationship. Rhizobium bacteria cause nodule formation for this association. The enzyme nitrogenase is highly sensitive to the molecular oxygen. The nodules protect these enzymes by an oxygen scavenger called leghaemoglobin.
Rhizobium bacteria are free living in soil. They are symbionts, which can fix atmospheric nitrogen for plants.