If you're on iOS there are a few "open source" tweaked YouTube ipa's you can sideload. The one I use has adblocking, Premium-free background playing, SponsorBlock and actual mp4 downloading built in. If you have an Apple Developer account, you can sign it once a year. If not, there ways of automating the weekly resigning (look up altstore).