If you've followed the instructions of installing Hadoop on your system from some online source and you've made sure to set the paths for your hadoop environment, it's quite simple
'cd $HADOOP_HOME/etc/hadoop'
'ls'
This will list all the files present in that folder and you'll find yarn-site.xml.
It's a common occurrence to not have a proper track of things during a Hadoop installation because when you use multiple online resources, you can have conflicts and inconsistencies in your paths and installation locations. It's highly recommended to take a proper big data course to overcome these problems. That way, you can get all your instructions from one source with no conflicts.