This is a particle which puts some shared context or knowledge of the conversation as a theme (topic) of the conversation and expects some development (rheme) on that topic.
It's a description in very broad strokes, and the details differ between affirmative sentences and questions, so bear with me.
Here's a couple of examples for affirmative sentences:
- — Сашина жена ему изменяет. — Он это знает. // "Sasha's wife is cheating on him". "He knows that".
This is a piece of watercooler gossip which can begin and end just like that.
- — Сашина жена ему изменяет. — Он-то это знает. // "Sasha's wife is cheating on him". "He knows that(, so what's next?)".
Here, the second party is telling two things:
Sasha knowing that the fact that his wife is cheating is somehow already in context. Maybe it's common knowledge. Maybe it's not relevant to the discussion. Maybe the second party thinks that "Sasha knows" or "Sasha doesn't know" is an expected response (so it's it context for them).
The discussion should further elaborate how to deal with this knowledge. This further development is kinda expected, so the second party cannot just stop conversation like that, that would be awkward.
So in a sense, the second party says "OK, I know you're expecting to hear whether or not Sasha knows his wife is cheating. I'll tell you that he does, because that's what you're expecting to hear, but at the same time I want to underline that I assume this should be past discussion and develop on that"
Note that the topic of the conversation is not whether Sasha knows or not. The topic is "We have established that Sasha knows". It's a very fine line but it's still there.
For questions, the shared context may be something that the parties have been discussing previously. So using -то might bring that thing back as a topic and expect some development on it.
— Мы едем в Америку. — А потом вы вернётесь? // "We're going to America". "Will you come back?"
The question is just a request for information.
— Мы едем в Америку. — А потом-то вы вернётесь? // "We're going to America". "About what happens next: you're coming back, aren't you?"
Somehow потом is a shared context.
Maybe the parties had some plans together. Maybe they had been discussing the come-back plans a minute ago but the second party forgot the details.
The second party perceives what happens after the trip to America as a shared context of the conversation, and wants to bring it back to discussion.
They are saying: "Somehow, I assume there is some implied "after the trip" that you will understand once I bring that up. So I'm bringing it up. What happens "after the trip"? Are you coming back?"