Coexistence of itinerant electrons and local moments in iron-based superconductors