The main result of this paper asserts that a monoid with finitely many left and right ideals is finitely presented if and only if all its Schutzenberger groups are finitely presented. The most important part of the proof is a rewriting theorem, giving a presentation for a Schutzenberger group, which is similar to the Reidemeister-Schreier rewriting theorem for groups.