The arm that took the pictures was there. It need not remain in the finished mosaic.

Image: NASA Astronomy Picture of the Day | Credit: NASA, JPL-Caltech, MSSS | Panorama: Andrew Bodrov | Original page
This self-portrait comes from Curiosity's sol 1943, January 23, 2018, on Earth. A Martian solar day is about 40 minutes longer than an Earth day.
NASA describes a mosaic of 61 exposures from MAHLI, the camera at the end of the rover's robotic arm. Its usual work is inspecting rocks at close range. For a selfie, the arm carries it through several positions, looking back at the rover from different directions.
If One Frame Is Blocked, Use Another
The arm does enter some pictures. But pictures from different positions do not always obscure the same ground. When assembling them, clear regions from another frame can supply the rover and actual landscape while leaving the arm out.
This is not an unprocessed snapshot. It also does not require inventing a patch of Martian terrain. It is a panorama assembled from multiple real photographs.

Diagram: The Daily Backstory; an illustration of frame selection, not the actual image-registration procedure.
The distant background comes from another time: Mastcam imagery taken on sol 1903. NASA explicitly identifies that addition. The panorama's parts are not all records of the same instant or the same camera.
A Ridge Named for an Astronomer
Vera Rubin Ridge honors the astronomer whose work on galaxy rotation supplied important evidence for large amounts of matter beyond what we can see. Her name is on Mars, while the search for direct evidence of dark-matter particles continues on Earth.
China's Jinping Underground Laboratory in Sichuan lies beneath 2,400 meters of rock. A 2023 Xinhua account describes a cosmic-ray flux about one hundred millionth of that at the surface, with Tsinghua University's CDEX and Shanghai Jiao Tong University's PandaX teams conducting research there. The second phase's civil and supporting works were completed in December 2023, expanding the underground experimental space to about 300,000 cubic meters.
"Quiet" does not mean free of every background signal. Thick rock reduces cosmic-ray interference; material selection, shielding and detector design address other sources. Evidence for dark matter's gravitational effects is not a claim that these detectors have already captured its candidate particles.
A rover uses several photographs to solve the problem of seeing itself. An underground laboratory uses a mountain to reduce unwanted signals. In either case, good measurement requires understanding both what to retain and what stands in its way.
Sources
NASA: Original page; JPL: the arm choreography behind rover self-portraits; Xinhua: Jinping Underground Laboratory.