Every time Ilya could find out about Shallergies is fascinating to me, so I'd like to add for science:
The CCM photoshoot. After Shane gets added, CCM inform Ilya that he cannot eat peanuts for at least 24 hours prior to the shoot (since they'll be in each other's faces and they don't want to risk killing the #2 overall pick).
Maybe the stylists gossip or smth, but it all amounts to Ilya knowing about the allergy from the jump and being one of the very few who don't treat him like he's fragile or deserves pity.
oh MAN okay okay: so i feel like they wouldn't be telling someone else's medical information, BUT i 100% feel like yuna puts things like an allergy-free set in shane's rider from the very start, and yeah she has to bring down the hammer sometimes especially when shane is new in his career so people are a little eyeroll about new kid on the scene being picky (it's one of the reasons she's ALWAYS on these sets with shane), but it's just a default of, "hey, craft services cannot have X, X, or X, and approved styling products are X, X, and X. all substitutions must be cleared by his management at least 48 hours in advance."
so ilya gets told as part of this shoot, "hey, we don't allow blah, blah, blah on set for allergy reasons" without saying there's actively a person who is being considered here. and ilya is new! he doesn't really know how all of this works yet no matter how confident he has to act about it, so as far as he knows, this is just how ad sets work. i also cannot remember of it was an ask or a question i got, but i THINK someone also told me that stuff like peanut allergy warnings are not super common in russia but relatively VERY more present in north america, so i also 100% buy ilya being like, "cultural thing, maybe? normal for over here?"
and he and shane are making smalltalk at the side of the rink, and ilya brings up that he organized the shoot, and he's still looking for more stuff to say to keep them talking (because tbh? just a lil nervous about talking to his crush especially after admitting he arranged this and still not sure if shane is vibing back or not and also still working on getting fully comfortable with english), so he brings up, "crazy we cannot even have peanut butter here, yes?" because again: DOESN'T KNOW THIS IS A SPECIFIC REQUEST. STILL THINKING THIS IS PROBABLY JUST A LIABILITY THING FOR AD SETS IN GENERAL OR SOMETHING.
and shane immediately is wondering if he's being made fun of or something?? did someone tell??? is rozanov being shitty about this?? is this a dig? but no. he said "we". he's not assuming it's shane's fault (wouldn't be his fault anyway, but it's how shane thinks about it). and he doesn't know rozanov yet, so he's not going to bust out his medical history when he doesn't have to, especially if he thinks rozanov MIGHT be shitty about it if he's going to bring up the set rules. so he just "yeah, they're pretty strict about it." so now ilya is just internally like 'yeah, so okay. this is how things go. his mom is his manager so she probably knows all the rules and told him. noted.' which tbh? kind of a relief. now he knows something important for this career (ooooh ilya).
so they agree to meet up, but ilya has now been thinking about the forbidden allergies purely the way you will when someone brings something up to you and tells you not to eat it (not even spitefully against the rules, just "man, someone mentioned peanut butter and said not to eat it, and now i REALLY want some peanut butter"), so he does something like get thai food with peanut sauce for dinner, and then obvi he has a mint right before meeting up with shane, but he's trying to act SO cool guy and going through the whole bother of brushing his teeth and using mouthwash would feel like Doing Too Much (jesus christ, teenaged boy with a crush). so his breath doesn't SMELL like peanuts, but he hasn't scrubbed any potential traces clear.
and the hookup with them happens pretty quick from first kiss to finishing, so shane at the end is catching his breath...and catching his breath...a-and catching...his breath. and then realizes that his throat and chest going so tight is a reaction and not just being fresh out of orgasm (and really FUCK his life. he gets the first sexual experience he has ever wanted and now THIS? FUCK his fucking EVERYTHING).
and ilya hasn't seen someone have a reaction before, so he doesn't actually know what's happening at first. is this? a freakout? "hollander, are you ok-" but then shane is scrambling up and tearing through his bag and ilya is just ?? what??? is goign on right now?? and then shane finds his epipen and doesn't want to sit on hotel floor because Gross but manages to wobble back to the bed and use it, and ilya STILL doesn't know?? what the fuck is happening?? but hollander couldn't really breathe right and now he stabbed?? himself?? with something?? and ilya can read context clues enough to understand that this is a medical thing, which is alarming, but also shane in the aftermath of using the epipen is shaking violently because that's just a side effect of it, and he's still catching his breath, but ilya bunches up the comforter to put around him because he thinks maybe he's just shivering??
and shane manages to get his breath back enough to say, "hey, ca-can you ca-call an ambulance?" and ilya is ?! yes but ?! and then shane realizes he's still naked so need to fix THAT first (fuck his FUCKING life), so he starts to get up and ilya (who is tbh a little freaked out right now because still doesn't know what's happening but shane looks Not Okay) just gently pushes him back down and grabs his (ever so helpfully neatly folded) clothes for him and puts them beside him on the bed and also puts his own clothes back on SO fast because obviously that needs to happen Now, and when he gets done, shane still hasn't gotten his shoes on or something because shaking still and also still has fucky blood pressure so getting a head rush leaning over, so ilya ends up helping.
and then ilya calls for him and also just. doesn't feel okay leaving him. their rivalry hasn't set in yet and this is the first time they've done anything so what even is there to hide (nothing obvious is on the bed, and beside a crumpled tissue in the bin, there's no other evidence), and also people already saw them talking during the shoot today so not beyond the realm of possibility that they'd just be doing more of that since they're already in the same hotel. and yuna was leaving the hotel earlier to get a drink with a friend or something who happens to be in town, so shane doesn't want to ruin that for her over a stupid reaction (and also wants to feel like an adult and not have to have his mom come running when she already stayed with him all day because of his allergies when he KNOWS it's noteworthy for someone's mom to be doing this), so when the paramedics ask about if anyone needs to be contacted or if anyone's coming along, he very honestly is like, "no, my mom's busy."
and ilya fully on impulse tells shane, "i can come. if you want." because like. he's already here. he still doesn't FULLY understand what happened here. but shane looks really sick rn and he knows from meeting her in the elevator that yuna was leaving the hotel, and he doesn't know why shane wouldn't just call (maybe she doesn't take her phone when she goes out?), but HE wouldn't want to take an ambulance ride by himself if he felt as bad as hollander looks right now (he almost certainly would end up doing it because who else would there be to come with him, but he wouldn't WANT to). and shane is a little thrown, but yeah, he doesn't know him well but it's not like he has a secret to keep from him at this point and maybe not a bad idea to have someone who can call his mom on his phone if he needs them to because of a secondary response or something.
so ilya ends up going to the hospital with him, and they end up talking because what else is there to do in this four hour observation window. and shane confesses to his allergies and being the reason the set couldn't have allergens on it. and ilya can read people. he can see that shane is bracing himself here. but ilya doesn't actually care. he'll chirp hollander and have fun with him, but he's not actually going to make fun of someone's medical condition, especially when they've ended up in the hospital because of it.
(and because. of him then eating something. that triggered that medical condition. oops.)
and they actually end up getting along during this time they've got 1:1, and of COURSE yuna finds out shane's not in his room because she went by to say goodnight and also hand over a new sponsorship deal someone sent over while she was out and got printed in the business center at the hotel to let shane look at it (prefers papers he can touch instead of reading on a phone), but shane?? didn't answer?? honey, you feeling okay?
and now yuna does end up at the hospital and is surprised at finding rozanov there, but as shane is scrambling, rozanov hops in with an excuse of saying he went up to see if shane wanted to work out together (a wink wink that only shane will understand lmao), but then shane started having a reaction. so now what yuna knows about ilya rozanov is that he was actively trying to hang out with her son and be friendly AND he then helped her child during an allergic reaction and even went with him to the hospital after.
and through the power of yuna, ilya and shane end up exchanging numbers because yuna won't say it but she's always excited when shane ends up making a new friend, so she drops a, "why don't you boys trade numbers? then you can hang out the next time you're in the same place for something."
so now they've started texting WAY earlier than in canon, and to shane's mom at least it's understood they're not really enemies right from the start (with the context of ilya is actually nice to shane in person, she understands that the rivalry is just an nhl narrative, and she understands marketing and spin), so she encourages shane in texting him, and even when they're in the same place (like at all stars), she encourages them meeting up and getting dinner together.
and for shane's part, ilya teases him about it later, but it's not mean or exclusionary. they plan on getting dinner with shane's parents for the first time or something and rozanov hits him with a, "i should order peanuts again and try to kill you, do you think? or is twice just bad manners?" and it's such a relief to have someone who thinks it's something that can just be joked about. rozanov doesn't treat him differently now except for asking shane now and then about stuff just because he's not wanting to kill shane the next time they meet up lol.
so even if it's not public, shane and ilya end up being friends (lol) WAY earlier and also have the space at least in private to be like, "i like you and you like me and there's an understanding between us that lets us hang out together and have it be not a big deal."