I've tried uninstalling and reinstalling both R and RStudio, manually installing the stats package, but nothing seems to resolve the issue. In my file explorer, I can see that the file specified in the error message exists on my computer. I've also tried updating my user PATH and I'm still getting the same error message.
If you run R from a command prompt, does the stats package load? You can tell by running library("stats") or ?lm -- if there is no error message, it presumably loaded.