On endomorphism rings and dimensions of local cohomology modules