A polynomial is a function, but a function is not necessarily a polynomial, there are functions that cannot be expresed as polynomials, such as sin x and ex, and there are much more general functions than that.
A function is a rule for associating members of one set (the domain) to members of another (the range). The price of shares of Microsoft stock on the NYSE, minute by minute, is a function, it associates he members of one set (minutes) to the members of another set (prices).
Some functions are easier to work with than others, polynomials are just about the easiest. But you need to get beyond thinking all functions are polynomials.