Occultation of planets by other planets Two Keplerian closed orbits always intersect:

Source: Astronomy SE answer by Flater
As seen from Earth, Venus appears larger than Mercury; this makes sense because Venus is both larger and closer than Mercury (as measured by minimal distance; by average distance all planets are equally distant), but can also be readily observed by comparing solar transits for either planet (or wait for 26 July 69,163, when both transit simultaneously).
Unless prevented by orbital resonance, that means that sometimes, Mercury should be eclipsed by Venus (occultation) when, seen from the Earth, Mercury is exactly behind Venus; and Mars should pass in front of the outer planets occasionally, but I'm not sure which body appears larger from Earth (Mars or Jupiter).
How often do occultations between planets occur?
What you describe is a mutual planetary occultation (or transit), and yes, it has happened—in 1737—and will happen again—in 2133 (both dates are for Venus/Mercury events; there are other possible instances of planets passing in front of each other; for example, in 2065, Venus will pass in front of Jupiter). I would suggest giving a look at https://en.wikipedia.org/wiki/Planetary_transits_and_occultations
What is interesting with Mercury and Venus is that, considering the respective positions of these planets as well as the Earth, it is technically possible for Mercury to pass in front of Venus! The last time it happened was in 796, and it won’t happen again at least until the year 2500. See More Mathematical Astronomy Morsels by Jean Meeus or the link above for more information as well as for the frequency at which mutual planetary transits occur.
A “near-miss“ will happen on 27 April 2022 at 19:11 UT, when Neptune will be very close to Venus—about 25″ depending on where you will be on the Earth at that moment…