What purpose did monks fulfill in the early days of the Church?

What purpose did monks fulfill in the early days of the Church? Describe the roles that learning and celibacy had in the life of Monasticism in the period before the Middles Ages (c. 900 AD).