I have encountered the same problem. While training an XGBoost model.
So here are couple of things which are worth giving a try:
Step 1: As mentioned earlier -
Use Anaconda Package > Download package (sklearn, xgboost) > Save
Note : Without clicking save, it won't install or uninstall the package.
Step 2 : After installing the packages > Restart your session
Note : Sometimes your session don't pick the installed package. So you need to restart your session.
Step 3: Verify the installed packages under Packages option. Also, there is an environment.yml file, under the files section.