Of all the many responses to 'Thank you', the phrase 'You're welcome' is the most useful. It means 'I was happy to help'.
We can say, for example, 'You're welcome to use my laptop' which means 'I am happy for you to use my laptop'. So, when we say 'You're welcome' after someone has thanked you, this is just a short form of 'That's ok. I was happy to help you'.
There are more formal responses, such as 'My pleasure' , and slightly more old-fashioned ones such as 'Not at all' and 'Don't mention it'.
There are also a wide range of more informal responses, such as 'That's ok', 'That's alright', 'No problem' (typically US) and 'No worries ' (typically Australian).
However, if you want a good, all-purpose response which is polite, natural, and suitable for any context, then 'You're welcome' is your best choice.