Monte Carlo modified profile likelihood in models for clustered data