Yes, but your 2i2 only has 2 outputs; left and right. In order to do a proper master output / cue output, you'd ideally want two stereo outputs (4 outputs).
You could try and configure the 2i2 for dual mono output with the left going to master and right going to headphone cue, but that may not be an option within rekordbox for you so you may need a workaround. Unfortunately we're not able to provide support for such 3rd party products so I'll leave this to the community to provide any other answers. Thanks.