It really depends on how you allocate costs. There is the manufacturing costs, which are a fixed cost for each unit, that doesn't change for a given volume. The other costs, such as R&D. software development, etc. cane allocated over the production run, split between similar projects, etc. The more you make the lower the total cost (fixed plus allocated) and you can price based on a planned production run. At some point the per unit revenue above manufacturing costs*units sold covers the total allocated costs, you have broke even and the product is making a profit.
So yah, if Apple planned to sell a million units and have only sold 100K so far the HomePod could be unprofitable based on the total costs and total revenue to date but that is not the whole picture.