How do I close the desktop app and keep the positions of windows?

To have all windows restore their position, you need to use Exit in the drop-down menu of the window title:

For the macOS version, this button can be found in the main application menu:

Home Stock Screener Forex Screener Crypto Screener Economic Calendar How It Works Chart Features Pricing Refer a friend House Rules Help Center Website & Broker Solutions Widgets Charting Solutions Lightweight Charting Library Blog & News Twitter
Profile Profile Settings Account and Billing Referred friends Coins My Support Tickets Help Center Ideas Published Followers Following Private Messages Chat Sign Out