Prosecutors granted immunity to an ex-girlfriend of Representative Matt Gaetz before she testified last week in front of a federal grand jury hearing evidence in the investigation of the congressman, according to a source familiar with the matter.