You misunderstand what a 51% attack can achieve.
A successful 51% attacker would mine and build a secondary blockchain in secret, with whatever transactions they like included in it. Once their own secret blockchain is longer than the main chain, they broadcast it to the network. Since they now have a longer chain with more proof of work, the rest of the network would automatically switch to this secondary chain, and the previous main chain would be abandoned. Any transactions which were included in the previous main chain but not in the newly accepted secondary chain would be reversed. This can happen after theoretically any number of confirmations, although with each confirmation it becomes exponentially harder and more expensive. However, a successful 51% attack would, at a minimum, be able to reverse or double spend transactions with 1 confirmation.
Most exchanges wait for at least 3 confirmations before confirming bitcoin, and some still wait for 6.
Thanks for the explanation o_e_l_e_o, after reading your comment i read more from other sources about the topic. You are right, it is not about a double-spend problem, it is a full block replace and a chain replacement.