If a cancerous tumor has a lot of mutations in them why can't the immune system detect them? If a person has cancer could this somehow alter the person's immune system so it doesn't function effectively to detect greatly mutated cells? Does the fact that a tumor is 'made' of 'mutated' non-foreign human cells help it to be undetectable?
This is a good question and it gets to the most basic foundations of immunology. Your immune system is made to be flexible - able to adapt to almost any challenge. However, with so much flexibility comes the potential to generate immune cells that react against the 'self'. So, at the other extreme, the immune system needs to be limited.
In order to meet these two (potentially conflicting) goals, immune (at least lymphocytes) cells have a two-step development pathway. In the first step, the body randomizes its immune receptor specificity. In the second step, it ensures that these receptors are not auto-reactive.
Doing so means that immune cells are aware of their environment at the time that they are 'born.' Take a look at this review from the Fuentes-Panana lab to read about how tumors actively cultivate the immune system of their host in order to maintain a more favorable environment.
Great question and in part, you are correct. However, you must also remember that this greatly depends on what genes have undergone mutation.
In the case of cancer, it's usually either a gene that regulates cell proliferation rates, induces programmed cell death or helps to repair damaged DNA. When one (or all) of these genes is mutated, the cell constantly proliferates and/or does not die when it is "programmed" to do so or cannot repair mutations to it's DNA, thus creating a cancerous tumor.
Now, on to the immune system. The reason a persons immune system does not target and kill it's own cells is because of a certain set of genes that is specific to each and every person called Major Histocompatibility Complex (MHC). These genes encode specific cell surface molecules that the immune system cannot produce antibodies to bind to because they are "locked", if you will (see, the immune has a sort of built-in list of genes that code for antibodies that bind to different sequences of molecules (that's how you develop immunity and fight pathogens), the genes that code for the specific molecules that your cells have on their surface are just not on that list.) In order for a person's immune system to recognize cancerous cells as a pathogen and destroy them, the cancer cell's MHC genes would also need to be mutated drastically.
For instance, breast cancer is usually caused by a mutation in the BRCA1 or BRCA2 genes. These genes assist in DNA repair. Even if this mutation happens, these cells still have the same MHC as the rest of the cells in your body because BRCA1 and BRCA2 don't really have much to do with MHC. Because of this, the immune system does not recognize the cancerous cells as a threat and is unable to destroy or even detect them.
I hope this answers your question.
Answering your two questions together, all cells enjoy many mechanisms that try to prevent the mutated ones from surviving. During the cell cycle of somatic and germinative cells, for example, there are three moments of verification in which the cell will undergo a kind of internal "check up". During the interphase, this process takes place between phases G1 and S and also at the end of phase G2. In the division, as soon as the interphase ends, there is also one more verification. If during one of these three steps any mutation is recognized, the cell will undergo apoptosis (regardless of whether the identified mutation(s) were in fact to induce a neoplasm in the tissue or not.
Now, if even with these three checks any or some mutations go unnoticed, the cell in question will go through cell division and the mutation(s) will be inherited by the new lineage that will follow; but this does not indicate that the cell will be cancerous, because for a cancer to develop it is necessary for specific mutations to occur in specific genes.
This was just some information I wanted to give you, now answering your question more directly: cancers as a whole enjoy very cunning mechanisms that aim both to make tumor cells indistinguishable from normal cells for the immune system as well as they try to make it very difficult for the many proteins of the Complementary System, which is a vital part of the recognition of abnormalities of the Immune System, to get closer. There are many mechanisms that tumor cells enjoy, but one that stands out is what is called the Malburg Effect. This effect, described by the German physician Otto Walburg, in the 20th century, in a simplified way, consists in the fact that cancer cells consume a much higher amount of glucose than healthy cells and still convert a good portion of this glucose into lactose. This considerable production of lactose makes the environment around the tumor or neoplastic tissue more acidic than usual, acidic enough to compromise the activity of the many proteins that play a role in recognizing abnormalities in the immune system. This is one of the many mechanisms that many cancers use, which, directly or indirectly, makes it difficult for the immune system to recognize it.
The Warburg Effect: How Does it Benefit Cancer Cells? https://www.ncbi.nlm.nih.gov/pmc/articles/PMC4783224
Another interesting point is that of the five existing therapies to treat cancers currently (chemotherapy, immunotherapy, target therapy, hormone therapy and surgery), immunotherapy consists precisely in "training" the immune system to know how to differentiate a cancer cell from a healthy cell . In a very simplified way, what they do is surgically remove a slide of your tumor or neoplastic tissue, identify the proteins present in the cell membranes of the cells that make up the collected material (among other molecules) and differentiate what is there only in the tumor. From the moment the tumor's own molecules are identified, a kind of vaccine is made, in order to introduce a cocktail with these tumor-specific molecules into the patient's body so that the immune system can then chase the tumor cells, knowing how to differentiate of healthy cells.
Cancer Treatment Vaccines - Immunotherapy - National Cancer Institute https://www.cancer.gov/about-cancer/treatment/types/immunotherapy/cancer-treatment-vaccines
There is also an explanatory video, if I'm not mistaken from Nature, very good to introduce the idea in a very general way of how immunotherapy and cancer vaccines work: https://youtu.be/jDdL2bMQXfE