The only legal way to download YouTube videos is through YouTube's own apps. Use an unapproved third-party YouTube download app and you're flouting YouTube's terms of service, potentially infringing copyright, and opening yourself up to a lawsuit.
Admittedly, that's unlikely to happen. But there's always the possibility that YouTube might want to make an example of some poor soul, just like the music industry did around the start of the last decade.
For example, in 2011, a federal court in Massachusetts upheld a $675,000 penalty against a Boston University graduate student for downloading 31 pirated songs online. YouTube hasn't done anything like that yet, and it doesn't seem likely to in the near future. But it would be perfectly within its rights to do so, so be warned.