A trademark is worth money, sometimes a lot of money. This is especially the case with well-known brands. Since a trademark owner often can not (or does not want to) produce every kind of product, a trademark owner can choose to license its trademark. Often for certain products and for certain countries/regions.
A good license agreement is the key. This agreement contains all conditions for the trademark use, for example what is allowed and what is not allowed, but also what qualities the products must meet. Poor quality products can affect your brand reputation of course. One of the most important aspects of an agreement is how you can end it again.
This was crucial in the case of the PHILIPS trademark. Philips had licensed its brand to Gibson for, among other things, headphones and soundbars. But after the recent Gibson bankruptcy, Philips was able to revoke the license based on a provision in the license agreement. The bankruptcy trustee remained empty handed, he would have loved to sell the license to a third party of course. Philips has done that now: the license has now been transferred to TPV.