I can’t speak as to why your teacher never told you, because they truly should have! Rosin buildup on the instrument will harm and wear away the protective varnish, which is bad for the wood. Buildup on the strings not only dampens vibration, but rosin hardens on the string. This can created a glass-like surface on the string and won’t allow the bow to adhere. A similar thing happens to bow hair when you constantly over-rosin.