You can do junk miles on a turbo and junk miles on the road - you can also do quality training and enjoy yourself on both.
Like most things it's about how you do it and I know several examples of people who've prepared very successfully for long, hilly rides or sportive events almost exclusively on a smart trainer connected to Zwift or Bkool etc. There's also several well known examples of pros using turbos/Zwift to successfully prepare for racing after injury or as part of their training generally - most notably Mat Hayman before his Paris Roubaix win, and Steve Cummings before his road race and TT double at the British national championships in 2017. So it certainly can be a fair bit more useful and relevant to real world cycling fitness than you suggest.
In answer to the OP's question, I guess it's up to the individual - some people almost exclusively do "virtual" miles on a turbo so they would obviously count them! But you're right that most people go faster and therefore cover more miles in a given time on Zwift etc than in the real world - I know I do - so you should take that into account when comparing with your previous years or with other people. So the answer is, it depends!