What were the things that King Louis XVI did during the French Revolution that led to his death?
In a sense, it was what Louis XVI did not do, rather than what he did, that led to his death.
Louis was officially executed for treason. But his trial was really not a legal trial but more of a political event. As the link below says, the charges against him were "trivial or vague" and "not susceptible of legal proof." Therefore we cannot really say that it was anything that he did that led to his conviction and death.
The one thing that Louis did that led to his arrest was to try to escape from France. He did this because he could not tolerate the policies of the revolutionary government. After the Revolution, Louis was still king, the head of a constitutional monarchy of sorts. He made many compromises with the new form of government, but he could not tolerate the changes the government was making in the Roman Catholic Church. He tried, therefore, to leave the country but was caught and imprisoned.
While he was imprisoned, a war started between France and Austria and Prussia. The leader of the Austrian/Prussian army, a cousin of Louis, issued a statement saying that his side would restore the king if they won. This was not something Louis himself did, but it helped lead to his death because it made him look like he was allied with the enemies of France.
Overall, Louis XVI was killed not because of what he did (try to escape) but because of what he did not do. He did not completely accept the changes that the revolutionaries were trying to make. Since many of them did not want a monarchy in the first place, this left him vulnerable and that is what really led to his death.