I am planning on making a 3D Maze but I am not able to start on creating the terrain. Can anyone please suggest any tutorials or sample code to start me off. I would like to use an OpenGL if possible.
Java3D is an actual API for doing 3D stuff you know. If you want to use OpenGL you should be looking at JOGL or LWJGL. Even more cool is LibGDX as that also makes deployment on Android possible.
I highly recommend that you sign up to java-gaming.org. That is a community of helpful java devs that focus on game development. Your question falls more in the generic game development department than an actual Java related question, I wouldn't expect help with that here.