Mr. Rivera’s arrest was a lead story for much of Tuesday evening and Wednesday on several conservative-leaning news websites, and was touted as a boost to the Trump administration’s argument for a more hard-line stance on immigration. The arrest came in the same week that an undocumented immigrant from Mexico was charged with second-degree murder in a Minnesota case.

Mr. Trump is expected to continue to push immigration as a signature issue in courting voters ahead of November’s midterm elections. In Iowa, Republicans are defending two congressional seats that Democrats have high hopes of winning, and Governor Reynolds is seeking a full term in her post.

The discovery of Ms. Tibbetts’s body devastated her hometown, Brooklyn, where she had returned for the summer after studying psychology at the University of Iowa. After weeks of anxiously awaiting news, some residents said Wednesday that they were frustrated to learn that the suspect in her death was in the country illegally.

“Mollie would still be alive today if we would just enforce the laws we already have in place,” said Kerry Traver, 73, who lives in nearby Marengo. “Here illegally and nobody’s doing anything about it.”

Rusty Clayton, owner of True Value Hardware in Brooklyn, said customers in the small town — where doors are seldom locked — have been coming in to have house keys made ever since news broke that Ms. Tibbetts was missing. But he said the town views its Hispanic residents not as outsiders, but as members of the community.

“Their kids go to our school,” Mr. Clayton said. “One was homecoming king, and another of the students has been valedictorian of the class. The kids here well respect them and interact with them.”