Chloé Zhao’s film depicts the inspiration for “Hamlet” as a relentlessly woeful tale.