Berlin did not have mobile connections inside the tunnels until very recently (this year, I believe). This included the trains not being connected to any outside network. Thus wifi on the subway was useless to implement.
Which provider are you with? Vodafone is still dead in large parts of the U-Bahn, but I know that one of them works much better.
I believe someone published a map of the data coverage of different providers on the berlin ubahn, but probably outdated now
I'm with sim.de which I believe is essentially an O2 reseller (apn references o2)
Summary: since 2024-05-06, users of all networks also get LTE in the U-Bahn thanks to a project between BVG and Teléfonica (not surprising that Teléfonica deployed the infra because they had the best U-Bahn LTE coverage beforehand)