SQL server always ON patching
The process to upgrade/patch Always On Availability Groups is documented extensively in the official SQL Server docs. Typically this is done as a rolling upgrade, where you move from secondaries to the primary SQL Server. Depending on your setup you would do the following:


Patch remote secondaries
Patch local secondaries
Perform a failover of the primary
Patch former primary


You don't typically do them all the same time, you roll through the servers. When I patch our servers, I normally do the secondaries one day and then the following, I'll perform the failover and finish patching the former primary.