That's an Ubuntu thing. They prefer you use apt to install deps, but you don't absolutely need to. The PROPER way to work around this is starting a localized python virtual environment for your project directory. That is essentially sandboxing a python environment that only installs dependencies into the project directory and doesn't alter your system globally.
Lots of instructions on the steps to do this out there that should get you going in just a few minutes.