Set a custom Video Mode for your project.
2:5 and 5:2 is just the aspect ratio. You would also need to set the exact resolution along with the FPS (Frames Per Second).
Example: A 2:5 aspect ratio could have a resolution of 432x1080.
Then choose GIF Animation from the Export presets. Export file.