Can Lugia be a legendary one that reproduces itself? In the official Pokedex, it says that Lugia does not have gender. In many games, there is only one Lugia.

But in EP221 a Lugia's pup is shown and captured by the Rocket team, and Lugia, hitherto genderless, is treated as "the mother who fights for her son."

If Lugia is a legendary and genderless type and, possibly, unique, how can he have a puppy? Legendary can reproduce even if they have no gender?
There are multiple Variations in the Pokemon Anime and Games. For instance, in the games, there exists only 1 of each Legendary/Mythical Pokemon. However, in the anime that is not the case.With regard to Breeding, the fact that Legendary/Mythical Pokemon happen to be genderless isn't a sole factor that determines its ability to breed as in the games, we know the gender of Latios, Latias, Thundurs, Landorus, Cresselia, Tornadus and Heatran. However, none of these pokemon can breed. Another misconception is if a pokemon has an ability to evolve, it should obviously be able to give birth to its pre-evolution. Type-Null and Cosmog both are Legendary/Mythical and evolve, however they cannot breed.Manapy seems to be the only exception that can breed in the games. Also note that eggs containing the Legendary Bird Trio; Articuno, Zapdos and Moltress can be hatched  in Pokemon Snap.The Baby Lugia seems to be one of the few exceptions in the anime.

In the anime, we also see weird pokemon like  an Old Treecko in the Episode where Ash catches one, a Humongous Giant Dragonite in season 1 , Crystal Onix and other different kinds of pokemon apart from the usual Shinies we are aware of. You can read more about the same here. I believe the Baby Lugia falls into this category.