Tried below commands
git remote set-url origin <new_url_after_repo_change>
git fetch --all
git reset --hard origin/master
Verified the new URL with below command.
git remote -v
Remote URL updated. But root folder name of repo didn't change
Just to answer my own question, which I posted 2 years back, there is no relation between git local repo root folder name and git remote repo name. When you clone a repo, local repo root folder will be same as remote repo name. Both local repo root folder name and remote repo name are independent of each other. When you change local repo root folder name, It doesn't impact the remote repo name even when you push the code. Similarly changing the remote repo name doesn't impact the local repo root folder name in your machine.
So, you can create a new empty folder with any name and make it a git repo with git init. You can point it to any remote repo. The local repo folder name and remote repo name needn't not be same. The same local repo can be pushed to multiple remote repos by adding the corresponding remote URLs.