Unable to install expo-cli

I am trying to install expo-cli, but after installation, when I try to verify installation with expo -v or expo whoami. It says that expo is not a valid command.
Command I used to install expo: npm i -g expo-cli, I also tried with npm install --global expo-cli.

NPM version: 6.14.5
Node Version: v14.5.0

One thing I noticed while installing was that it was giving some warnings about depreciations. I think the problem could be that but I am not sure how to solve that