[DependencyInjection] Fix ticket #10663 - Added setCharset method call to PHP templating engine

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #10663
| License       | MIT
| Doc PR        | N/A