There are a few potential reasons for this:
- Rule of Funny. Most of the shows you linked are comedies, and someone speaking pseudo-German nonsense in a bad accent is inherently funnier than someone speaking actual German (unless you're a native German speaker).
- It's not worth it. Again, most of the clips are from sitcoms (which are not $100m productions), and are only a single throwaway scene. If the German was pivotal to the plot, they'd be more likely to take the time and effort to make sure it was accurate, but for a single scene they can just make up whatever and say "yeah, that sounds good enough". [This is also the reason why, in many old WWII movies, the Germans all speak English in bad accents rather than German]
- They didn't think anyone would notice. These shows are made primarily for an American audience, and most Americans don't speak German. They'd watch these scenes and think the German is perfectly valid.
- Alternately, a Genius Bonus/Bilingual Bonus for anyone who does speak German. They'd watch the scene and be able to recognize, as you did, that the person is speaking nonsense.
It's worth noting that this phenomenon isn't unique to English-language works, either. Anime in particular is infamous for its terrible English (partly for budgetary reasons, partly due to linguistic differences). My personal favourite is Kiniro Mosaic, in which two of the main characters were born and raised in England and one of them is pure-blooded English, yet neither of them sounds even remotely English when they speak (I'll link a video example when I get the chance).: