The simple answer to "Why penalize returning from death?" is, "You should not." The more complex answer has everything to do with the difference between a consequence and a penalty.
There are a couple of broad categories of character creation, which hopefully match the style of the particular D&D campaign. They're very different approaches, and it makes it impossible to have one perfect approach to handling the issue of character death in D&D. One approach is driven by narrative, the other is driven by mechanics. Narrative character generation starts, unsurprisingly, with the story of the character and puts some numbers on to quantify those narrative traits. Mechanical character generation reverses that, hanging a story (often sparse) on the framework of the numbers. Most of us have probably done it both ways at one time or another. How that character is created often has a long-reaching impact on how the character is played, how the character is spec'd on level-up, and the expectations the player will have regarding character death, and returning from it.
If you are dealing with a narrative character in a narrative campaign, then death should have narrative consequences. Even if you're DMing the game in a largely procedural, mechanical way, that's when you turn to the indefinite madness tables, lingering injury tables, etc. If your DMing style is more focussed on the narrative, you probably have given some thought to what will happen to the story when characters die, and how the story will accommodate either a return from the dead or the introduction of a new character. This is the time for the side mission to the outer planes to free the character's soul, or the journey to the home of the NPC who can, for a price, bring a character back from the dead. The consequences for the death of a narrative character should be grounded in the narrative of the campaign, even if there are mechanical repercussions (like the cost of material components or falling behind the xp curve.)
If you are dealing with a mechanical character, then even if you tweak the campaign narrative because of its death, the repercussions should be largely mechanical. This is not likely to be a player that wants to derail the main quest for a side story to bring the dead PC back, it is much more likely that this player will want to reroll, or to accept whatever mechanical cost there is for bringing the character back from the dead. This player has probably been thinking about the race/class combo they want to try next anyway.
The important distinction is that for the narrative character, the story of bringing it back from death (if done right) is a reward, not a penalty. For the mechanical character, a chance to re-roll can (sometimes) also be rewarding. Conversely, the permanent destruction of a character with a huge narrative investment shouldn't be taken lightly--if the death isn't epic, and doesn't offer a satisfying conclusion to the character's story, then you should consider providing an "out," whether it's a deal with a devil, or coming back as a revenant, or divine intervention with an appropriately weighty plot element. In the same way, forcing a lot of narrative onto a mechanical character shouldn't be done lightly--a lot of players would probably rather tear it up and start over than spend a lot of time mucking about with the narrative fallout of any kind of character-driven story arc focused on bringing their PC back from the dead. They don't want a relationship with the Raven Queen, if they can't just buy the diamond and move on they'd rather stat up the new arcane trickster with ritual caster and an owl familiar they've been thinking about lately.
The job of the DM is not to run the NPCs and draw up battle maps. That's a big part of how the DM does the job, sure... but the actual job is to provide a fun experience for the players. You don't do that with punishment and penalties, but you do get a lot done by making sure that the choices the players make have consequences, whether good, bad, or indifferent. Just keep in mind that, based on the player and the character, a "bad" consequence can be rewarding, while a "good" consequence could be regrettable. As a DM you have many different ways to deal with a dead character, and none of them will be "the right way" in every circumstance. What makes D&D better than a computer RPG is that you have the flexibility to choose the outcome that your players will ultimately enjoy.