https://www.jetbrains.com/help/idea/creating-virtual-environment.html
Project settings -> Facets -> expand Python click on child -> Python Interpreter
Project settings -> Modules -> Expand module -> Python -> Dependencies -> select Python module SDK