It might be useful to look at how 23andme works, to see how this analysis product is generated, in general:
The 23andMe genotyping platform detects single nucleotide polymorphisms (SNPs). A SNP is a DNA location, or "marker," in the genome that has been shown to vary among people in terms of the DNA base or bases. There are four DNA bases: adenine (A), thymine (T), guanine (G), and cytosine (C). So, for example, at the same genomic location, you might have a C and someone else might have a T. These DNA base differences are known as "variants."
These SNPs can differ by population types. Some subsets of a population type might suffer a disease and appear to have SNPs that others do not. So-called GWAS studies (discussed below) work at associating SNP distributions with diseases or other phenotypic traits.
You send some spit to 23andme, they tell you who you are likely related to and what diseases or other physical attributes you may have, based on patterns of these SNPs.
23andme uses Illumina chips for figuring out what genotypic variants you have in the spit sample you send to them. Illumina is a company that manufactures "chips" that react to the presence or absence of markers in the DNA sample you send to 23andme. Each chip in this platform calls different sets of markers.
These markers often have identifiers associated with them, each called an rsID.
The rsID number is a unique label ("rs" followed by a number) used by researchers and databases to identify a specific SNP (Single Nucleotide Polymorphism). It stands for Reference SNP cluster ID and is the naming convention used for most SNPs.
They also map variants that do not use rsIDs, and instead use some other internal identifier.
Whatever the identifier, GWAS — Genome-Wide Association Studies — are research projects that analyze populations of people in different ethnicities or other cohorts, looking for over- or under-presence of various markers, compared with the larger human population.
For instance, here is such a GWAS study that is used by 23andme to indicate risk factors for Parkinson's disease, in sample donors who have these variants. There are other such studies for schizophrenia, for autoimmune diseases, and so on.
The power of these studies to make a positive, correct association depends on various factors, but the product 23andme sells is ultimately a packaged summary of a lot of work by researchers around the world.