Typically when we talk about a note or scale degree being consonant or dissonant we are usually relying on harmonic or intervalic context. The terms “consonant” and “dissonant” usually deal with the relationship of two or more notes, (see wikipedia for consonance and dissonance, which says as of today "In music, a consonance [...] is a harmony, chord, or interval considered stable”.)
Thus, I find your statement
I've got the information that 1st, 3rd, 4th, 5th, 6th notes are
consonants and 2nd and 7th notes are generally dissonant.
to be somewhat misguided. A note can only be dissonant based upon context. For example, in C natural minor, the leap from D -> Ab is a tritone, which is a dissonant interval. In order for a scale degree to be considered dissonant or consonant would require that it be compared to the preceding or subsequent melodic note, or to the underlying harmony.
As far as whether this is still relevant in modern music, it depends on genre. But in most genres the concept of intervalic consonance/dissonance is still very relevant.
Edit: I tried to soften the absolutism of my answer a bit in response to Pat's valid comment that "there are higher-level dissonances such as relation to the overarching key". This is definitely true but I think context is still paramount. For example in a completely silent room if I think inside my mind "I'm going to play a note from the key of C major", then walk up to the piano and play a B, that note is not intrinsically dissonant. Only if I first establish the tonal center can it be heard as a leading tone. I think it is appropriate to steer the OP in the direction of harmonic and melodic context and away from the idea that scale degrees are inherently consonant or dissonant.