Multiwavelength characterization of the accreting millisecond X-ray pulsar and ultracompact binary IGR J17062–6143