sudo python3 setup.py install # TLDR; try with sudo
chown -R user-id:group-id /path/to/the/directory
This can happen either becuase the file is in use by another proccess or your user doesn't have access