If a bacterium had a protein on its surface that humans also have, would it cause an autoimmune disease?
It's believed that many autoimmune cases are triggered by what you describe - pathogens or opportunist bacteria and viruses that contain proteins similar to human proteins.For example:


Autoimmunity to hypocretin and molecular mimicry to flu in type 1 narcolepsy
Translocation of a gut pathobiont drives autoimmunity in mice and humans
Autoantigen cross-reactive environmental antigen can trigger multiple sclerosis-like disease


However, it's important to understand that although these cross-reacting proteins may be required in the process of autoimmunity, they aren't sufficient to cause autoimmunity alone (or else everyone would have autoimmunity all the time). Autoimmunity needs to have a whole bunch of steps, including several pieces of genetic susceptibility and environmental conditions, before the specific trigger will cause a problem (and it's likely that once the many other conditions are satisfied, there are multiple potential triggers that can set up the final cascade).