When the Jewish people were being rounded up by the Nazis to be sent to concentration camps etc, was there a lot of work done by the state to ensure that the correct people were being rounded up? For example, are there any cases where someone was sent to the camps who wouldn't have been regarded by the Nazi state as an enemy and thus sent in error? How did they identify who was Jewish and who wasnt, was just case of checking national records? Lastly was there any Jews who actually avoided being sent away by pretending to be other religion etc?
To your last question, many people tried to hide this way, but it was not accessible for everyone. For example men and boys were less likely to be able to hide like this, because they were circumcised and most non Jewish men were not. You also generally had to find a non-Jew to live with and to corroborate your identity. People like this were few and far between. The most common way was for children to be placed in orphanages or monasteries. After the war many did not want to let these children have Jewish identities again because they felt they had saved their souls through conversion. Anyway, people who hid by hiding their identity needed resources, needed the ability to hide by being willing to leave behind their families, needed a social network, to have the “right” looks, to know non Jewish customs, prayers, and mannerisms, to speak the local dialect perfectly and without any hint of Yiddish. In short it wasn’t easy, and many who hid this way were discovered and killed. As to your other question, a case of mistaken identity like this would be highly unlikely. Remember the Holocaust didn’t start with mass killings, it started with identification and isolation. By the time deportations or mass shootings occurred you would not have say a gentile standing in a crowd of Jews about to be shot or deported to their deaths unless that person was helping the Nazis, or less likely were helping the Jews and in that case would be killed as a partisan, not for mistaken identity. Prior to large deportations the Judenrat, or Jewish council would be ordered to recompile community lists. People like Chaim Rumkowski of Łódź were hated by survivors for handing over lists of the children of the Łódź Ghetto. When the Nazis occupied a territory there were a few different outcomes. If the Jews in the area were to be killed by Einsatzgruppen, the Jews would be asked to gather on pain of death and most would. In these areas you have to remember that Jews were often easily identifiable by language or clothing, they were not integrated and their non Jewish neighbors often harbored animosity towards them, identifying these people was not hard. After they were killed lists of numbers killed were compiled by their killers and many such as the Jager Report from Lithuania are extant and readily available. In areas where Jews were not killed outright they were identified by community of government records, by obvious belonging to the community, by neighbors, or by themselves. People did not know in 1939 what was coming in 1942. Most would have been scared enough to follow the orders to register as Jews, or to wear identifying marker. At the beginning they would have seen not following those orders as more immediately dangerous than following them. The Jewish councils set up by the Nazis were almost always forced on point of death to keep lists, which would later be used for murder, it was usually horribly easy for the Nazis to identify their victims