Why can't mortgage be modified instead of refinanced?

Secondary loan market holds clue