As senshin says, it's kind of a bizarre question since people in real life often do this too, but as our raison d'être here is to overanalyze everything, here goes.
In most of the cases the OP lists, as well as most of the ones I can think of, the quirk of obsession with a single food makes a character seem childlike and immature. While adults have likes and dislikes, they tend not to be as extreme with them as children and teenagers. An adult might like ramen, but a teenager will like ramen so much that they eat nothing else, and have to be hospitalized for lack of vitamins.
This portrayal can serve a few different narrative purposes:
- It makes a character seem charmingly simple-minded. Naruto and Luffy are both heroes after the mold of Goku: they love eating and fighting and have lofty goals that seem unattainable to other characters. Having them obsess over ramen or meat goes with being oblivious and childish. Ren in DearS, or Ayu from Kanon, are also childlike characters, and their love for melon bread / taiyaki helps create that image.
- Conversely, it can add a charm point for a character who seems unapproachable. This seems to be why Shana loves melon bread. It's also why the Monogatari series's immortal vampire Oshino Shinobu loves donuts. Angel Beats's main character Otonashi first bonds with impassive Kanade after he notices that she keeps ordering tongue-burning mabo tofu in the cafeteria. I would also put L here. While L and his successor Near are pretty much always the smartest person in any given room (we can debate about whether that's true when Light is in the room), and have command over various police forces, they also have strange, childish quirks: in L's case, constantly eating sweets, and in Near's case, constantly playing with toys.
An interesting case of (2) is Code Geass. The show had some kind of product placement deal with Pizza Hut. Supposedly, the director thought putting Pizza Hut all over the place was funny (I heard this claim on an ANNCast episode), so they went to ridiculous lengths to put Pizza Hut boxes in as many scenes as possible. The character C.C., mostly a pretty formidable lady, has an obsessive love for Pizza Hut which surpasses her love for life itself. According to the Code Geass wiki:
C.C. also has a somewhat obsessive penchant for pizza, especially
Pizza Hut's Cheese-kun (which sponsors Code Geass in Japan); she
constantly orders pizzas to Lelouch's house using his credit card,
much to his chagrin. This is often used for comedic effect. Her love
for pizza is so strong that she is willing to risk herself being
captured, twice nearly exposing herself to get a piece of a giant
pizza being made by the Student Council (which is ruined both times);
both Lelouch and Kallen sometimes refer her as "Pizza Girl". In
addition to this she is an avid collector of Cheese-kun related
merchandises and is often seen hugging a Cheese-kun plush doll.
The Pizza Hut logo was blanked out of the US versions of the show, apparently because Bandai couldn't make a deal with Pizza Hut in the US.