The actor voluntarily sought treatment for suicidal thoughts, according to records obtained by PEOPLE