If he is not able to maintain erection then you should consult the endocrinologist
as the treatment is available.
The drugs like sildenafil
are available which makes the erection last longer and is taken one hr before sexual intercourse.
The psychological cause, hormonal deficiency
should also be ruled out after consulting the doctor.
The treatment is according to cause.