#include <bits/stdc++.h>
using namespace std;
long long fastpow(long long a, long long b,
                  long long m = (long long)(1e9 + 7)) {
  long long res = 1;
  a %= m;
  while (b > 0) {
    if (b & 1) res = (res * a) % m;
    a = (a * a) % m;
    b >>= 1;
  }
  return res;
}
long long timer;
const long long LG = 22, maxN = 1e5 + 5;
long long tin[maxN], tout[maxN];
long long up[maxN][LG + 1];
vector<long long> adj[maxN];
long long depth[maxN];
void dfs(long long v = 1, long long p = 1, long long d = 0) {
  tin[v] = ++timer;
  up[v][0] = p;
  depth[v] = d;
  for (long long i = 1; i <= LG; ++i) {
    up[v][i] = up[up[v][i - 1]][i - 1];
  }
  for (long long u : adj[v]) {
    if (u != p) {
      dfs(u, v, d + 1);
    }
  }
  tout[v] = ++timer;
}
bool isAncestor(long long u, long long v) {
  return (tin[u] <= tin[v]) and (tout[u] >= tout[v]);
}
long long LCA(long long u, long long v) {
  if (isAncestor(u, v)) return u;
  if (isAncestor(v, u)) return v;
  for (long long i = LG; i >= 0; --i) {
    if (!isAncestor(up[u][i], v)) {
      u = up[u][i];
    }
  }
  return up[u][0];
}
long long dist(long long a, long long b) {
  long long lca = LCA(a, b);
  return depth[a] + depth[b] - depth[lca] * 2;
}
int32_t main() {
  ios_base ::sync_with_stdio(false);
  cin.tie(nullptr);
  cout.tie(nullptr);
  ;
  long long n;
  cin >> n;
  long long u, v;
  for (long long i = 0; i < (n - 1); i++) {
    cin >> u >> v;
    adj[u].push_back(v);
    adj[v].push_back(u);
  }
  dfs();
  long long q;
  cin >> q;
  while (q--) {
    long long x, y, a, b, k;
    cin >> x >> y >> a >> b >> k;
    long long p1 = dist(a, b);
    long long p2 = dist(a, x) + dist(b, y) + 1;
    long long p3 = dist(a, y) + dist(b, x) + 1;
    if (p1 <= k and !((p1 & 1) ^ (k & 1))) {
      cout << "YES" << endl;
    } else if (p2 <= k and !((p2 & 1) ^ (k & 1))) {
      cout << "YES" << endl;
    } else if (p3 <= k and !((p3 & 1) ^ (k & 1))) {
      cout << "YES" << endl;
    } else {
      cout << "NO" << endl;
    }
  }
  return 0;
}
