Forced to stay home during the coronavirus outbreak, many residents of the central Chinese metropolis of Wuhan rely on delivery drivers such as Zhang Hao, who risks infection himself as he zooms around the city by moped to deliver groceries and other supplies.

In return, some of his customers treat him as a potential carrier of the virus. One woman waited for Mr. Zhang, 36 years old, to back away from her package before she sprayed it with disinfecting alcohol and took it upstairs. Others ask why he is working and whether...