Get ready for more mixed signals. The Cambridge Grammar of the English Language (CGEL) gives an analysis that differs dramatically from the other answers here.
It says that yesterday, today, tonight, and tomorrow are pronouns. The evidence:
- Like I and you, they're deictic. Which day yesterday is depends on the context of the speech act, i.e. when you say it.
- Unlike common nouns, they don’t take determiners. You can’t say The yesterday was great.
- Unlike adverbs and prepositions, they have a possessive form. Compare: [Usually’s / After’s / Now’s / Yesterday’s] performance was great.
(It doesn't mention Shakespeare’s “...And all our yesterdays have lighted fools the way to dusty death.” which shows yesterday acting a lot like a noun. I suppose they’d say that’s just Shakespeare playing with words.)
In a case like "I have an important meeting tomorrow," it seems as if they're nouns.
CGEL spends several pages on “temporal location expressions”. They are sometimes but not always adverbs. Several examples are given of noun phrases that specify time: I have an important meeting [Tuesday / tomorrow / the day after tomorrow / every day / next month / right this minute]. That is, certain noun phrases can be tacked onto a sentence in just the same way as an adverb or a prepositional phrase.
But what about "Yesterday afternoon?"
Here the pronoun yesterday functions as a determiner. This is not something pronouns normally do; it's an oddball case.
Determiners include the bolded expressions in twelve angry men, my red tennis shoes, a sandwich, your father's truck, three or four billion dollars. A singular count noun generally needs a determiner in front of it if it's going to function as, say, the subject of a sentence. Compare: [This afternoon / Yesterday afternoon / Afternoon] was great.
Apparently the days of the week can also serve as determiners this way: Sunday afternoon.