No – only one version of Yahoo! Messenger works at a time.
If you try signing in to Yahoo! Messenger for the Web while you’re running the desktop ‘client’, you’ll get an option to click either: