First of all, in HTTP/1, header names are case-insensitive. See https://tools.ietf.org/html/rfc7230#section-3.2. Then, in HTTP/2, all header names must be encoded in lowercase (https://tools.ietf.org/html/rfc7540#section-8.1.2).
So, internally, for convenience and consistency matters, we decided to store them in lowercase. You may be surprised by this conversion because you don’t use HTTP/2. But think about h2 clients sending requests to h1 servers. All headers will be in lowercase. Same is true for h2 servers replying to h1 clients.
If it is a problem for your application, you can disable the HTX format with
no option http-use-htx. But note that the old HTTP format (called legacy HTTP) will be removed in HAProxy 2.1. If there are too many complaints about the subject, we will try to address it using a map or something of that taste. Note also, in legacy HTTP, headers are not “capitalized”. So if a client sends a request with a funny case, the problem will be the same for your application.