We saw them visiting starbases on many occassions, in fact. So why go to the trouble of storing five years' worth of food?
Probably because space is a dangerous place. All you'd need would be a warp failure and no communications and you'd be stuck in the middle of nowhere. At least five years of supplies would give you
some leeway to developing a strategy to either get moving at warp again, or to improvise a way to send a message back to a base for a rescue mission.
The Bantam tie-in novels tended to assume that the 5YM continued to completion after TOS. When ST:TMP came out, some commentators reported things like Kirk's mission had "ended prematurely", but they were assuming the mission ended abruptly/early like the TV series itself had.
Several of Pocket Books' tie-in authors originally assumed a
second 5YM (or at least, an open-ended one) for Kirk and the Enterprise between TOS and TMP, mainly to explain the chronological aging of the cast in the intervening ten years. When the first licensed Chronology and Encyclopedia came out, the Okudas had suggested shifting this second mission to post-TMP, and later tie-in novels complied with this concept.
When Diane Duane's "Rihannsu" novels were recently re-released as an omnibus, the dates in her first two were reconfigured to match the timings suggested by new canonical evidence (such as dates mentioned by Icheb in VOY), and the concept of a second longterm mission between TMP and ST II, which the other novelists had been doing for about a decade.