Method for manufacturing magnetic substrate and common mode filter