Plants grow best in fertile soils, full of the right sort of 'foods' for them.
These are called 'nutrients' and one of the most important is nitrogen. Beans
(and other plants of the same family called Legumes) have a special way of making
nitrogen available for themselves - and, later, for other plants. So growing beans
is a good way to make your soil richer.