When I was young, 'lady' was the polite word to use; 'woman' was rather derogatory; in the 1960s and 70s, some females began to regard 'lady' as pretentious, preferring 'woman'. A few years ago, 'lady' appeared to be making a comeback.
Nowadays, I find it safer to avoid the words if at all possible, saying such things as "She's a teacher" (no need to add a gender-defining adjective) and "She's an interesting person to talk to". When I am in conversation with female people () I try to use the word that they use of themselves.
If I have to talk about the female half of the species in general, I use 'woman/women' - "Women are still under-represented in the boardroom".
Off-topic ps. As a linguist, I still think of 'gender' as being associated with language, 'sex' with living beings, but I have learnt to use 'gender' for both
Student or Learner