Currently, there are several Poison- and Bug-type legendary and mythical Pokemon. Ultra Beast and Paradox Pokemon do not qualify as legendary.
- Poison Types:
- Legendary:
- Eternatus
- Silvally (holding Poison Memory)
- The Loyal Three:
- Okidogi
- Monkidori
- Fezandipiti
- Mythical:
- Pecharunt
- Arceus (holding Toxic Plate)
- Bug Types:
- Legendary:
- Silvally (holding Bug Memory)
- Mythical:
- Genesect
- Arceus (holding Insect Plate)
All the Poison-types were introduced after the question was posted. As for why there's only one legend/mythic Bug-type, and no legend/mythic poison types until gen 8, we can't really know that because it was Gamefreak's decision. Here's my theory for Bug:
Imagine yourself trying to come up with a legendary Pokemon design for a new game. Legendaries are supposed to have a powerful, somewhat mysterious vibe, so chances are, you're going to think of some (ironically) "mythical"- seeming creature, likely a Dragon-like monster... (there are 15 legend/mythic Dragon-types). Now if you make a type for this, you'll make it dragon-something. Even if one were to try to intentionally make a Bug-type legendary, bug is usually the primary type, (because if you make a bug it's primarily a bug, and if you make a non-bug it's not really a bug at all) and legendary dous and trios always share a primary type, so you would have to make a pair of bugs as the most powerful Pokemon in your game, which wouldn't really feel right. This is why I think the only legendaries that can be Bug-type are Arceus and Silvally, which they had to make a Bug-type for because they can be every type.
And for poison, I feel like it just kinda works better for early game Pokemon. Legendary Pokemon are usually tied to grand, elemental concepts (like time, space, life, and creation). Historically, Poison has been viewed in gaming as a "sneaky" or "subversive" attribute rather than a god-like power. Also, over half of all Poison types were introduced in Gen 1, where the type was mostly associated with pollution, waste, and common animals. Because Game Freak heavily associated it with early-game, low-tier Pokémon (like the Grimer, Koffing, and Zubat lines), it took many generations for the type to be culturally associated with legendary power, and they didn't make that many ever again. Eventually they decided that it was time to make a couple poison legends though. The last sentence of my Bug-type explanation goes for this too.
Source 1: experience/personal opinions
Source 2: List of Legendary and Mythical Pokemon- Bulbapedia