I am collaborating on a project with others, and there is a .gitignore in the root directory which is committed to git. What if I wanted to make a new file or directory in root
You can set an additional gitignore file for the current repository with the core.excludesfile config option (as mentioned in the comments):
core.excludesfile
git config core.excludesfile .my_gitignore
And add your personal files to this file (as well as ".my_gitignore" itself).
.my_gitignore