Problem while building a project - 'platformio' is not recognized as an internal or external command

I’m trying to use CLion to write code for Arduino, and I’m getting this error whenever I try to build:

====================[ Build | Production | nanoatmega328-MinGW ]================
"C:\Program Files\JetBrains\CLion 2022.2.3\bin\cmake\win\bin\cmake.exe" --build C:\Users\pc00520\CLionProjects\signal_engine\cmake-build-nanoatmega328-mingw --target Production -j 12
[1/1] cmd.exe /C "cd /D C:\Users\pc00520\CLionProjects\signal_engine && platformio -c clion run -enanoatmega328"
FAILED: CMakeFiles/Production C:/Users/pc00520/CLionProjects/signal_engine/cmake-build-nanoatmega328-mingw/CMakeFiles/Production 
cmd.exe /C "cd /D C:\Users\pc00520\CLionProjects\signal_engine && platformio -c clion run -enanoatmega328"
'platformio' is not recognized as an internal or external command,
operable program or batch file.
ninja: build stopped: subcommand failed.

This is my first time to use PlatformIO and I have no idea how to solve this issue. I download a PlatformIO for CLion with IDE and had no problem while creating a project since I tried to build it. Has anyone seen this before and fixed it?

Using:
Windows 10
CLion 2022.2.3
Python 3.10

For CLion to be able to use PlatformIO you have to expose the PlatformIO binaries in your PATH as documented: See Install Shell Commands — PlatformIO latest documentation