Any unhidden, undownloaded content will normally be shown in your library allowing you to stream or download on demand. For reasons that aren't exactly clear new purchases can sometimes be hidden from your purchase history. Check the view menu to make sure that you haven't selected Only Downloaded Music. If needs be see Hide and unhide music, movies, TV shows, audiobooks, and books - Apple Support to unhide any hidden content and then (Re)download music - Apple Support to download it to local storage.
If iTunes or Music show multiple instances of an artist or an album then what generally works is to select all related tracks and use Song Info to add say a trailing X to each of the fields that the tracks should have in common:
- For an album; Album, Album Artist, and Artist (if artist is the same for all tracks) *
- For an artist; Album Artist (and Artist unless there are guest/featured artists listed which should not be changed)
Apply the change which merges things together, then remove the excess characters. Occasionally it may help to close and reopen the app between the two renaming operations. Part of a compilation should also be set consistently.
* If tracks are to be synced to a non-iOS device there should be a common Artist and/or the album should be set as a Compilation.
Use the songs view and display the fields Album, Sort Album, Album Artist, Sort Album Artist, Artist and Sort Artist side by side so you see whether or not it is appropriate to edit Artist and if sort values could be causing any further problems. See Grouping tracks into albums for more help if required.
One further tip for really stubborn duplicates. At one point I had three lots of Various Artists in the artists view of my iTunes Match library that wouldn't respond to the usual trailing X treatment. What I found worked was to add the trailing X to start with, but then with each group that iTunes wanted to keep separate start typing a value and let it autocomplete from say Var... to Various Artists. Picking from the autocomplete lists seemed to work when pasting/editing the whole value didn't.
tt2