What is the term in linguistics when a word comes to have a new meaning over time, e.g 'wicked' is commonly used to demonstrate this

It is called semantic change (also semantic shift, semantic progression or semantic drift).