Lattice simulations of cotranslational folding of single domain proteins