A law meant to end surprise medical billing accidentally created a multibillion-dollar industry that is making doctors richer.