Where...or whom...did you get the idea that coffee was a vice from? The same person who told you rhubarb, asparagus or broccoli was a vice?
Well, technically caffiene is a drug albeit a mild and fairly benign one.
Intentionally ingesting the drug could arguably be contrued as a vice.