How to stop destructible mesh from being destroyed when character touch it (UE5)

you could have it such that when the event which makes the sword swing animation fires, it queries if an object is overlapped. If so, send an interface message to the overlapped actor saying, “player has swung sword and you have been hit!”

then the hit actor can decide what they want to do from that event. Trigger teh destruction, etc.

You will want to research “blueprint interfaces” to make that happen. But to test the basic idea, you can just get the hit actor and cast to them directly.