I assume that “the visitor” you are referring to in this question is the man that Sam calls “Bando.” Bando is the first human that Sam meets in the woods and he is the only person who gives Sam a nickname. The nickname that Bando gives to Sam is “Thoreau.” You can find the first instance of Bando calling Sam by this nickname at the bottom of page 77. (This is in the chapter “I Find a Real Live Man” in case your edition has different page numbers.)
When Sam meets Bando, he believes that Bando is a criminal who is on the run from the police. He names him “Bando” because that is short for “bandit.” However, Bando is not really a criminal. In fact, he is a professor of English. He decides to call Sam “Thoreau” because Sam seems to be living like Henry David Thoreau. The actual Thoreau wrote a book called Walden about a two-year time period when he tried to live a very simple life where he could immerse himself in nature and be self-sufficient. Sam is trying to do essentially the same thing that Thoreau did, which leads Bando to use that nickname.