Can you hide behind the illusion? Probably. Can you get advantage just for being behind it? Probably not unless you're a halfling.
Here's the problem, ultimately, you're only creating a 5' cube. That's probably not enough to hide behind without an actual stealth check.
Basically, you need to completely block line of sight from the creature you want advantage on, to yourself. You also, theoretically need to maintain said blockage of line of sight to your opponent until the moment you attack...
The way this probably works best is if you're a halfling and cast this the turn before. Then you could duck back, and shoot through the illusion with advantage.
For a normal sized character, without an action to hide, I'd probably not allow you to remove yourself from LOS behind the illusion (that's not to say that it doesn't block). Most characters are over 5' tall (a huge swath of humans are, like probably 80% or more, and likely even more adventuring humans). That means that even though you only take up a 5' cube in game space, you'd be seen over an illusory one. You'd get cover...but the thing is an illusion so if you're shot at, I'd give the creature the impression you had cover, but none would be applied to the attack (or maybe half the cover number, so -1 or -2 instead of -2/-5). Advantage on you attacks though, not so much.
However, if you're willing to spend the action (to make a dex(stealth) check) to hide, I'd acknowledge that, because you're actually spending a whole action, and that is modeled by being quiet, stepping softly, and possibly crouching behind an illusory object.
So yes, the wall is opaque, and you'd be able to hide behind it/have advantage from attacks (technically, if it was a real object, they wouldn't be able to target you..I'd allow the targeting)...but only if you completely fit behind it, and that's not the case for most PCs.