You can use a Rigid Transform block to re-orient the Z axis before the Prismatic Joint block, so it is in the direction you want (i.e., the Y axis in the base frame).
This was an intended design in Simscape Multibody to ensure consistency. You know that if you have a Prismatic Joint, you should expect motion on the Z axis of that coordinate frame.
- Sebastian