Extended atmosphere of the yellow hypergiant V509 Cas in 1996-2018