Trump will do anything to gain personal, political capital.  I believe this offer is more about aligning himself with the Pope's concern than a real show of compassion. His visit with the Pope was less than stellar and I think he is trying to ingratiate himself with the Pope.  He has shown how fragile his ego  is in the face of anyone's displeasure.  The Pope definitely didn't look pleased on that occasion.