That is not how DNA samples generally work. Have you ever acted as an attorney in a sexual assault or a child custody case? I’m guessing not. In a civil case, the DNA found of the garment is compared with that of the defendant’s DNA.In this case, Trump refused to provide his DNA for over 3 years. So the plaintiff had nothing to compare the DNA found on her dress with.
I am not ignorant of the value of DNA. Modern technology can help build picture of what the donor looks like.
For example:
https://abcnews.go.com/US/state-trooper-dna-helped-catch-mass-joggers-alleged/story?id=46841780
Also, we know Donald Trump’s ancestry. We can predict which haplogroups he is likely to have and where his autosomal cousins hail from.