Periodic solutions of nonlinear functional differential equations