The will was improperly created
In order to be valid, a will must be signed by two witnesses who are not receiving anything in the will. In addition, the person making the will must sign it in front of the witnesses, or the witnesses must otherwise confirm that the signature belongs to the person making the will. If these conditions are not met, the will is invalid.
The person making the will didn't understand what they were doing
A will can be challenged on the basis that the person making the will did not have the mental capacity to understand what they were doing when they signed the will. For example, a person with dementia might not understand what they are signing.
The will was created by fraud
Sometimes, a will is created by someone else and passed off as the will of the deceased. This includes cases where someone forges the signature of the person supposedly making the will. In other cases, an individual is tricked into signing a will because they are told and believe that it is something else entirely.