On a Mac, you can do this to copy it to your clipboard (like cmd + c shortcut)
cat ~/Desktop/ded.html | pbcopy
pbcopy < ~/.ssh/id_rsa.pub
and to paste pbpaste > ~Documents/id_rsa.txt
or, use cmd + v shorcut to paste it somewhere else.
~/.ssh is the same path as /Users/macbook-username/.ssh
You can use Print work directory: pwd command on terminal to get the path to your current directory.