Yes some are related to mental illness.
Thyroid problems can present like clinical depression hence it should be ruled out first. ECG is to know your cardiac status before starting medications as they can affect the heart rarely. Others are routine to rule out infection,
vitamin deficiency etc which also could affect mood. Even if you are only 25years it’s better to make sure that you are physically fit before starting on medications.