Your question is very difficult to answer because Koreans have very different ways of responding to such a bad news and it will entirely depend on sex of the responder, (social) position of the speaker and responder, age of the deceased, etc. Basically, there is no idiomatic expression such as "I am (so, very) sorry to hear that (the news)."
If a speaker is your friend, you could consider saying:
진짜! 마음이 많이 아프겠다. (Literally) Really? It must hurt your feeling a lot.
or
얼마나 마음 고생이 심했니. (Literally) How much you suffered mentally (emotionally).
If a speaker is your senior or elder as in your case, you could consider saying:
얼마나 상심이 크시겠어요. (Literally) How broken-hearted you are.
or
얼마나 마음 고생이 심하셨겠어요. (Literally) Honorific of 얼마나 마음 고생이 심했니.
'상심' literally means 'feeling of loss" and '마음 고생' literally means 'hardship (suffering) of mind'.
There could be more.